Skip to content
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

Remove login_required decorator #315

Merged
merged 2 commits into from
Apr 24, 2024
Merged

Remove login_required decorator #315

merged 2 commits into from
Apr 24, 2024

Conversation

nas-tabchiche
Copy link
Contributor

The login_required decorator was used before we switched to DRF to redirect to login page if there were no user authenticated. Since we were using session authentication up until recently, the decorator had no impact on the proper functioning of the view, even though it overlapped with the permission_classes.
It broke when we switched to token-based authentication, since it checks for session objects, which are no longer used.

The login_required decorator was used before we switched to DRF to redirect to login page
if there were no user authenticated. Since we were using session authentication up until
recently, the decorator had no impact on the proper functioning of the view, even though
it overlapped with the permission_classes.
It broke when we switched to token-based authentication, since it checks for session objects,
which are no longer used.
Copy link
Collaborator

@eric-intuitem eric-intuitem left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@nas-tabchiche nas-tabchiche merged commit 296534d into main Apr 24, 2024
11 checks passed
@nas-tabchiche nas-tabchiche deleted the hotfix/backup-import branch April 24, 2024 07:01
@github-actions github-actions bot locked and limited conversation to collaborators Apr 24, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants