mirror of
https://github.com/GAM-team/GAM.git
synced 2025-07-03 11:13:42 +00:00
Make set/show signature consistent. (#292)
* gam user foo signature should set signature on primary address for backwards compatability gam user foo show signature already does this * Simply signature/show signature, don't loop to get primary
This commit is contained in:
@ -5878,14 +5878,11 @@ def getSignature(users):
|
|||||||
user, gmail = buildGmailGAPIObject(user)
|
user, gmail = buildGmailGAPIObject(user)
|
||||||
if not gmail:
|
if not gmail:
|
||||||
continue
|
continue
|
||||||
result = callGAPI(gmail.users().settings().sendAs(), u'list',
|
result = callGAPI(gmail.users().settings().sendAs(), u'get',
|
||||||
soft_errors=True,
|
soft_errors=True,
|
||||||
userId=u'me')
|
userId=u'me', sendAsEmail=user)
|
||||||
if result:
|
if result:
|
||||||
for sendas in result[u'sendAs']:
|
_showSendAs(result, i, count, formatSig)
|
||||||
if sendas.get(u'isPrimary', False):
|
|
||||||
_showSendAs(sendas, i, count, formatSig)
|
|
||||||
break
|
|
||||||
|
|
||||||
def doVacation(users):
|
def doVacation(users):
|
||||||
if sys.argv[4].lower() in true_values:
|
if sys.argv[4].lower() in true_values:
|
||||||
|
Reference in New Issue
Block a user