'Encapsulating the rules for whether the request was to a Flask endpoint'

def _has_fr_route(self):

    if self._should_use_fr_error_handler():
        return True
    if (not request.url_rule):
        return False
    return self.owns_endpoint(request.url_rule.endpoint)
