From c0c13552162d362c692143dc1156b7b8ca470b05 Mon Sep 17 00:00:00 2001 From: Ross Scroggs Date: Wed, 4 May 2022 09:41:35 -0700 Subject: [PATCH] Handle missing type field in multivalued schema valus (#1520) --- src/gam/__init__.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/gam/__init__.py b/src/gam/__init__.py index 1a7795e9..59aa3bbc 100755 --- a/src/gam/__init__.py +++ b/src/gam/__init__.py @@ -9042,8 +9042,9 @@ def doGetUserInfo(user_email=None): if isinstance(user['customSchemas'][schema][field], list): print(f' {field}:') for an_item in user['customSchemas'][schema][field]: - print(f' type: {an_item["type"]}') - if an_item['type'] == 'custom': + an_type = an_item.get('type', 'work') + print(f' type: {an_type}') + if an_type == 'custom': print( f' customType: {an_item["customType"]}') print(f' value: {an_item["value"]}')