Skip to content

Commit 02d4fa2

Browse files
committed
Update to latest version of auth plugin
For some reason, downstream repos had a newer version but we forgot it in the upstream repo.
1 parent 2d764db commit 02d4fa2

File tree

1 file changed

+2
-12
lines changed
  • tools/communityauth/sample/django

1 file changed

+2
-12
lines changed

tools/communityauth/sample/django/auth.py

+2-12
Original file line numberDiff line numberDiff line change
@@ -47,12 +47,12 @@
4747

4848

4949
# This signal fires when a user is created based on data from upstream.
50-
auth_user_created_from_upstream = Signal(providing_args=['user', ])
50+
auth_user_created_from_upstream = Signal()
5151

5252
# This signal fires whenever new user data has been received. Note that this
5353
# happens *after* first_name, last_name and email has been updated on the user
5454
# record, so those are not included in the userdata struct.
55-
auth_user_data_received = Signal(providing_args=['user', 'userdata'])
55+
auth_user_data_received = Signal()
5656

5757

5858
class AuthBackend(ModelBackend):
@@ -374,13 +374,3 @@ def user_import(uid):
374374
auth_user_created_from_upstream.send(sender=user_import, user=u)
375375

376376
return u
377-
378-
379-
# Try to load the key (and throw it away) to verify that the format is
380-
# correct.
381-
try:
382-
k = base64.b64decode(settings.PGAUTH_KEY)
383-
if len(k) != 32:
384-
raise Exception("PGAUTH_KEY must be 32 bytes long")
385-
except Exception as e:
386-
raise Exception("Invalid PGAUTH_KEY: {}".format(e))

0 commit comments

Comments
 (0)