Changeset 448 for elixir/trunk/elixir

Show
Ignore:
Timestamp:
03/23/09 11:56:17 (3 years ago)
Author:
ged
Message:

Fixed using to_dict with a ManyToOne relationship in the "deep" set and that
relationship being None in the entity being converted.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • elixir/trunk/elixir/entity.py

    r443 r448  
    10351035            fks = self.mapper.get_property(rname).remote_side 
    10361036            exclude = [c.name for c in fks] 
    1037             if isinstance(dbdata, list): 
     1037            if dbdata is None: 
     1038                data[rname] = None 
     1039            elif isinstance(dbdata, list): 
    10381040                data[rname] = [o.to_dict(rdeep, exclude) for o in dbdata] 
    10391041            else: