rset.py
branchstable
changeset 5667 04cbd80fd5dc
parent 5532 1fa6e09605a5
child 5671 3a2063b752f3
--- a/rset.py	Fri Jun 04 11:09:55 2010 +0200
+++ b/rset.py	Fri Jun 04 13:07:07 2010 +0200
@@ -600,7 +600,11 @@
         if rel is not None:
             index = rel.children[0].root_selection_index()
             if index is not None and self.rows[row][index]:
-                return self.get_entity(row, index), rel.r_type
+                try:
+                    entity = self.get_entity(row, index)
+                    return entity, rel.r_type
+                except NotAnEntity, exc:
+                    return None, None
         return None, None
 
     @cached