Be able to change enabled status for cognito-idp users
This commit is contained in:
parent
2bb3d07e11
commit
1b42c7bf7a
4 changed files with 54 additions and 2 deletions
|
|
@ -394,6 +394,14 @@ class CognitoIdpBackend(BaseBackend):
|
|||
|
||||
return user_pool.users.values()
|
||||
|
||||
def admin_disable_user(self, user_pool_id, username):
|
||||
user = self.admin_get_user(user_pool_id, username)
|
||||
user.enabled = False
|
||||
|
||||
def admin_enable_user(self, user_pool_id, username):
|
||||
user = self.admin_get_user(user_pool_id, username)
|
||||
user.enabled = True
|
||||
|
||||
def admin_delete_user(self, user_pool_id, username):
|
||||
user_pool = self.user_pools.get(user_pool_id)
|
||||
if not user_pool:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue