Added a reset of failed_login_count when the user is activated.

Update user from the update-password api call (which resets the failed_login_count)
This commit is contained in:
Rebecca Law
2017-02-28 11:56:40 +00:00
parent b37e7fd188
commit 2d4e0a0631
2 changed files with 2 additions and 1 deletions

View File

@@ -152,6 +152,7 @@ class UserApiClient(NotifyAdminAPIClient):
def activate_user(self, user):
if user.state == 'pending':
user.state = 'active'
user._failed_login_count = 0
return self.update_user(user)
else:
return user