From 99c793e2ad2cbe351650970ae5baad8a93c5a817 Mon Sep 17 00:00:00 2001 From: Kevin McCarthy Date: Thu, 4 Oct 2007 12:20:00 -0700 Subject: Fixes none values in first/last name to display properly. --- ipa-python/entity.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'ipa-python/entity.py') diff --git a/ipa-python/entity.py b/ipa-python/entity.py index 2f0629cda..7afc3e63a 100644 --- a/ipa-python/entity.py +++ b/ipa-python/entity.py @@ -79,9 +79,9 @@ class Entity: """Get the list (array) of values for the attribute named name""" return self.data.get(name) - def getValue(self,name): + def getValue(self,name,default=None): """Get the first value for the attribute named name""" - value = self.data.get(name,[None]) + value = self.data.get(name,default) if isinstance(value,list) or isinstance(value,tuple): return value[0] else: -- cgit