Ticket #3077: svn.diff

File svn.diff, 682 bytes (added by Nikolaus Schlemm <nikl@…>, 18 years ago)

patch against current trunk

  • django/core/management.py

     
    150150        if isinstance(f, (models.ForeignKey, models.OneToOneField)):
    151151            rel_field = f.rel.get_related_field()
    152152            data_type = get_rel_data_type(rel_field)
     153            while isinstance(rel_field, (models.ForeignKey, models.OneToOneField)):
     154                rel_field = rel_field.rel.get_related_field()
     155                data_type = get_rel_data_type(rel_field)
    153156        else:
    154157            rel_field = f
    155158            data_type = f.get_internal_type()
Back to Top