Fix code to account for Google API change that prevented clearing a user's recovery phone. (#1116)

Before you had to pass None and the value, now you pass an empty string just like recovery email
This commit is contained in:
Ross Scroggs
2020-03-13 05:24:22 -07:00
committed by GitHub
parent 0256a3f267
commit e7eea5b9d2

View File

@@ -6140,11 +6140,8 @@ def getUserAttributes(i, cd, updateCmd):
i += 2
elif myarg in ['recoveryphone']:
body['recoveryPhone'] = sys.argv[i+1]
if body['recoveryPhone']:
if body['recoveryPhone'][0] != '+':
body['recoveryPhone'] = '+' + body['recoveryPhone']
else:
body['recoveryPhone'] = None
if body['recoveryPhone'] and body['recoveryPhone'][0] != '+':
body['recoveryPhone'] = '+' + body['recoveryPhone']
i += 2
elif myarg == 'clearschema':
if not updateCmd: