Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Custom middlewares break the app#7426

Merged
wardi merged 3 commits into
masterfrom
flask-login-middleware-with-flask-app
Mar 14, 2023
Merged

Custom middlewares break the app#7426
wardi merged 3 commits into
masterfrom
flask-login-middleware-with-flask-app

Conversation

@smotornyuk
Copy link
Copy Markdown
Member

FlaskLogin middleware expects the original flask application, not the one, wrapped in the custom middleware. We are initializing FlaskLogin after applying IMiddleware interface, which means that if any of the plugins registers custom middleware, FlaskLogin won't work

Solution:
pass the original flask app to the FlaskLogin.

@wardi wardi self-assigned this Mar 7, 2023
@wardi wardi merged commit 6d6c742 into master Mar 14, 2023
@wardi wardi deleted the flask-login-middleware-with-flask-app branch March 14, 2023 12:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants