diff options
author | Mike Bayer <mike_mp@zzzcomputing.com> | 2010-04-01 19:06:35 -0400 |
---|---|---|
committer | Mike Bayer <mike_mp@zzzcomputing.com> | 2010-04-01 19:06:35 -0400 |
commit | 367bc4a9e53889afde6966ba210ccfe11dbe57c3 (patch) | |
tree | 777e9ce84d158b37d6ad36f67055e113aaa3ea8d /lib/sqlalchemy/orm/unitofwork.py | |
parent | 62cf9c8f8f7252473da26b8bafa5ffa6e3b22f92 (diff) | |
download | sqlalchemy-367bc4a9e53889afde6966ba210ccfe11dbe57c3.tar.gz |
working through cycles tests...
Diffstat (limited to 'lib/sqlalchemy/orm/unitofwork.py')
-rw-r--r-- | lib/sqlalchemy/orm/unitofwork.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/sqlalchemy/orm/unitofwork.py b/lib/sqlalchemy/orm/unitofwork.py index 4dd9878d5..3118e0b9f 100644 --- a/lib/sqlalchemy/orm/unitofwork.py +++ b/lib/sqlalchemy/orm/unitofwork.py @@ -145,15 +145,15 @@ class UOWTransaction(object): def states_for_mapper(self, mapper, isdelete, listonly): checktup = (isdelete, listonly) - for state, tup in self.states.iteritems(): - if tup == checktup: + for state in self.mappers[mapper]: + if self.states[state] == checktup: yield state def states_for_mapper_hierarchy(self, mapper, isdelete, listonly): checktup = (isdelete, listonly) for mapper in mapper.base_mapper.polymorphic_iterator(): - for state, tup in self.states.iteritems(): - if tup == checktup: + for state in self.mappers[mapper]: + if self.states[state] == checktup: yield state def execute(self): |