Skip to content

Reload user object after BEFORE_LOGIN/CREATE_USER hooks are run#70

Open
alxbridge wants to merge 2 commits into
fangli:masterfrom
torchbox:master
Open

Reload user object after BEFORE_LOGIN/CREATE_USER hooks are run#70
alxbridge wants to merge 2 commits into
fangli:masterfrom
torchbox:master

Conversation

@alxbridge

Copy link
Copy Markdown

If a user's is_active status is changed in the configured BEFORE_LOGIN or CREATE_USER functions, this change isn't seen when checking is_active to log the user in, so they can be incorrectly granted/denied access based on the stale value. This PR fixes this by reloading the user object before the check.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant