Revert "Stop automatically resending email verification links"

This commit is contained in:
Katie Smith
2019-01-21 15:44:15 +00:00
committed by GitHub
parent 061235958e
commit 398aef6d4c
4 changed files with 32 additions and 30 deletions

View File

@@ -129,7 +129,13 @@ class UserApiClient(NotifyAdminAPIClient):
return True, ''
except HTTPError as e:
if e.status_code == 400 or e.status_code == 404:
return False, e.message
if 'Code not found' in e.message:
return False, 'Code not found'
elif 'Code has expired' in e.message:
return False, 'Code has expired'
else:
# TODO what is the default message?
return False, 'Code not found'
raise e
def get_users_for_service(self, service_id):