Django

Code

Changeset 3510

Show
Ignore:
Timestamp:
08/01/06 16:15:41 (2 years ago)
Author:
mtredinnick
Message:

Refs #1796 -- Fixed a problem when creating models with relations to
themselves: more than one instance was being created.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/trunk/django/db/models/fields/related.py

    r3414 r3510  
    2626    # Has the model already been loaded? 
    2727    # If so, resolve the string reference right away 
    28     model = get_model(rel_cls._meta.app_label,field.rel.to
     28    model = get_model(rel_cls._meta.app_label, field.rel.to, False
    2929    if model: 
    3030        field.rel.to = model