mirror of
https://gitlab.com/allianceauth/allianceauth.git
synced 2026-02-09 08:36:23 +01:00
Correct SeAT API logic (#860)
* Do not attempt to change user email on SeAT if unchanged. This prevents HTTP422 from being raised on password resets. *Delete users on deactivation. The existing disable user logic does nothing and results in a HTTP500. It's safe to delete users entirely - the API keys are retained. Fixes #844
This commit is contained in:
@@ -28,7 +28,7 @@ class SeatTasks:
|
||||
|
||||
@classmethod
|
||||
def delete_user(cls, user, notify_user=False):
|
||||
if cls.has_account(user) and SeatManager.disable_user(user.seat.username):
|
||||
if cls.has_account(user) and SeatManager.delete_user(user.seat.username):
|
||||
user.seat.delete()
|
||||
logger.info("Successfully deactivated SeAT for user %s" % user)
|
||||
if notify_user:
|
||||
|
||||
Reference in New Issue
Block a user