Tweak check for request.resolver_match in extension templatetags.
Review Request #12000 — Created Jan. 26, 2022 and submitted — Latest diff uploaded
I recently added a check inside the
init_js_extensions
method to check
whetherresolver_match
was present on the request. This can be missing
in the case where middleware decides to render a page instead of
delegating to the regular view (typically something like a 403). The
check I added wasn't quite correct, and could still fail in some cases.
This change updates it to address those cases.
Ran Review Board test suite where this was being hit.