ashb commented on a change in pull request #13620:
URL: https://github.com/apache/airflow/pull/13620#discussion_r555790125
##########
File path: airflow/www/extensions/init_views.py
##########
@@ -171,6 +185,7 @@ def _handle_api_error(ex):
api_bp = connexion_app.add_api(
specification='v1.yaml', base_path=base_path, validate_responses=True,
strict_validation=True
).blueprint
+ app.after_request(set_cors_headers_on_response)
Review comment:
```suggestion
# Like "api_bp.after_request", but the BP is already registered, so we
have to
# register it in the app directly.
app.after_request_funcs.setdefault(api_bp.name,
[]).append(set_cors_headers_on_response)
```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]