From: Tony Mack Date: Thu, 9 Jul 2009 20:36:34 +0000 (+0000) Subject: access dictionary by key instead of getattr X-Git-Tag: sfa-0.9-0@14641~86 X-Git-Url: http://git.onelab.eu/?a=commitdiff_plain;h=21a641e70d829e2bcdd5cdb839624edcffe0a8c3;p=sfa.git access dictionary by key instead of getattr --- diff --git a/sfa/util/record.py b/sfa/util/record.py index bfa166fe..35b5faaa 100644 --- a/sfa/util/record.py +++ b/sfa/util/record.py @@ -214,7 +214,7 @@ class GeniRecord(dict): if fieldname == "key": val = self.get_key() else: - val = getattr(self, fieldname) + val = self[fieldname] if isinstance(val, str): return "'" + str(val) + "'" else: