From fd8edb5aa2124ceecc5cc0329184e7dc7632e04e Mon Sep 17 00:00:00 2001 From: mdipierro Date: Thu, 27 Sep 2012 14:09:05 -0500 Subject: [PATCH] fixed issue 1032, thanks Carlos --- VERSION | 2 +- gluon/dal.py | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/VERSION b/VERSION index f7014c49..bd09f532 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -Version 2.0.9 (2012-09-27 14:05:37) stable +Version 2.0.9 (2012-09-27 14:09:01) stable diff --git a/gluon/dal.py b/gluon/dal.py index b3648155..0340eebd 100644 --- a/gluon/dal.py +++ b/gluon/dal.py @@ -6379,6 +6379,8 @@ class Row(object): def __contains__(self,key): return key in self.__dict__ + has_key = __contains__ + def __nonzero__(self): return len(self.__dict__)>0 @@ -7077,6 +7079,8 @@ def index(): # The instance has no .tables attribute yet return False + has_key = __contains__ + def get(self,key,default=None): return self.__dict__.get(key,default) @@ -7635,6 +7639,8 @@ class Table(object): def __contains__(self,key): return hasattr(self,key) + has_key = __contains__ + def items(self): return self.__dict__.items()