Make returning is_domain conditional

During an upgrade, a node running this code may need to handle a
persisted token (UUID, PKI, or PKIZ) created without this attribute.

Closes-Bug: 1630259
Change-Id: I0c5959b6491bb13a02eb1b9b7e7e37d2f2d73f85
This commit is contained in:
Lance Bragstad 2016-10-04 18:25:44 +00:00 committed by Dolph Mathews
parent 2b53c547cb
commit 4fd55f230b
1 changed files with 2 additions and 1 deletions

View File

@ -210,7 +210,8 @@ class KeystoneToken(dict):
@property
def is_domain(self):
if self.version is V3:
return self['is_domain']
if 'is_domain' in self:
return self['is_domain']
return False
@property