Skip to content

Commit

Permalink
Avoid building a big set of allowed_users if allow_all is configured
Browse files Browse the repository at this point in the history
Co-authored-by: Min RK <[email protected]>
  • Loading branch information
consideRatio and minrk authored Jul 3, 2023
1 parent 4dba5cf commit 5c940e6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion oauthenticator/oauth2.py
Original file line number Diff line number Diff line change
Expand Up @@ -610,7 +610,7 @@ def add_user(self, user):
"""
if not self.validate_username(user.name):
raise ValueError("Invalid username: %s" % user.name)
if self.allow_existing_users:
if not self.allow_all and self.allow_existing_users:
self.allowed_users.add(user.name)

def login_url(self, base_url):
Expand Down

0 comments on commit 5c940e6

Please sign in to comment.