mirror of
https://github.com/nikdoof/test-auth.git
synced 2025-12-14 14:52:15 +00:00
Update access when the key fails
This commit is contained in:
@@ -96,6 +96,8 @@ def import_apikey_func(api_userid, api_key, user=None, force_cache=False, log=lo
|
|||||||
account.api_status = API_STATUS_OTHER_ERROR
|
account.api_status = API_STATUS_OTHER_ERROR
|
||||||
account.api_last_updated = datetime.utcnow()
|
account.api_last_updated = datetime.utcnow()
|
||||||
account.save()
|
account.save()
|
||||||
|
if account.user:
|
||||||
|
update_user_access.delay(account.user.id)
|
||||||
return account
|
return account
|
||||||
|
|
||||||
# Create or retrieve the account last to make sure everything
|
# Create or retrieve the account last to make sure everything
|
||||||
|
|||||||
Reference in New Issue
Block a user