-
-
Notifications
You must be signed in to change notification settings - Fork 227
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Type of g.flask_httpauth_user #130
Comments
The |
Thanks for your response. |
@tabebqena You can access a lot of things that you are not supposed to use directly. |
Thanks for clarification. |
After successful authentication, What is the type of g.flask_httpauth_user that is added by the
@login_required
decorator?I expect to find
user
object, But As I can understand from the source code, It is alwaysstr
orNone
. In the case of string it will be theusername
.If my note is true, It will is better to change this behavior to store
user
object. If this will break the backword compatibility, I suggest to add optional user loader callback, that will be called after successful login.The current behavior break the example mentioned :
basic_auth.current_user()
return theg.flask_httpauth_user
which has no method namedget_token()
Thank you.
Version: 4.4.0
The text was updated successfully, but these errors were encountered: