Skip to content

Commit

Permalink
Remove references to RelatedObject
Browse files Browse the repository at this point in the history
  • Loading branch information
macro1 committed Apr 13, 2015
1 parent d279347 commit 48b4e80
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions simple_history/models.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,6 @@
from django.apps import apps
except ImportError: # Django < 1.7
apps = None
try:
from django.db.models.fields.related import RelatedObject
except ImportError:
RelatedObject = None
try:
from south.modelsinspector import add_introspection_rules
except ImportError: # south not present
Expand Down Expand Up @@ -305,13 +301,6 @@ def get_field(self, other, cls):

def do_related_class(self, other, cls):
field = self.get_field(other, cls)
if not hasattr(self, 'related'):
try:
instance_type = cls.instance_type
except AttributeError: # when model is reconstituted for migration
pass # happens during migrations
else:
self.related = RelatedObject(other, instance_type, self)
transform_field(field)
field.rel = None

Expand Down

0 comments on commit 48b4e80

Please sign in to comment.