mirror of
https://github.com/GAM-team/GAM.git
synced 2025-07-03 11:13:42 +00:00
catch additional errors on guardian delete
This commit is contained in:
@ -2361,7 +2361,7 @@ def doDeleteGuardian():
|
|||||||
guardianId = sys.argv[3]
|
guardianId = sys.argv[3]
|
||||||
studentId = sys.argv[4]
|
studentId = sys.argv[4]
|
||||||
try:
|
try:
|
||||||
callGAPI(croom.userProfiles().guardians(), u'delete', throw_reasons=[u'notFound'], studentId=studentId, guardianId=guardianId)
|
callGAPI(croom.userProfiles().guardians(), u'delete', throw_reasons=[u'forbidden', u'notFound'], studentId=studentId, guardianId=guardianId)
|
||||||
print u'Deleted %s as a guardian of %s' % (guardianId, studentId)
|
print u'Deleted %s as a guardian of %s' % (guardianId, studentId)
|
||||||
except googleapiclient.errors.HttpError:
|
except googleapiclient.errors.HttpError:
|
||||||
# See if there's a pending invitation
|
# See if there's a pending invitation
|
||||||
|
Reference in New Issue
Block a user