fix login_hint issues

This commit is contained in:
Jay Lee
2016-11-03 14:30:14 -04:00
parent 26fbf9c524
commit 6becd08f3c

View File

@ -9986,9 +9986,7 @@ See this site for instructions:
print u'ERROR: the format of your client secrets file:\n\n%s\n\n is incorrect. Please recreate the file.' print u'ERROR: the format of your client secrets file:\n\n%s\n\n is incorrect. Please recreate the file.'
sys.exit(3) sys.exit(3)
try: if not login_hint:
login_hint = sys.argv[3]
except IndexError:
while True: while True:
login_hint = raw_input(u'\nWhat is your G Suite admin email address? ') login_hint = raw_input(u'\nWhat is your G Suite admin email address? ')
if login_hint.find(u'@') == -1: if login_hint.find(u'@') == -1:
@ -10441,7 +10439,7 @@ def ProcessGAMCommand(args):
elif command in [u'oauth', u'oauth2']: elif command in [u'oauth', u'oauth2']:
argument = sys.argv[2].lower() argument = sys.argv[2].lower()
if argument in [u'request', u'create']: if argument in [u'request', u'create']:
doRequestOAuth() doRequestOAuth(login_hint=sys.argv[3])
elif argument in [u'info', u'verify']: elif argument in [u'info', u'verify']:
OAuthInfo() OAuthInfo()
elif argument in [u'delete', u'revoke']: elif argument in [u'delete', u'revoke']: