Ticket #4050: base.py.3.diff
File base.py.3.diff, 780 bytes (added by , 18 years ago) |
---|
-
django/db/models/base.py
23 23 def __new__(cls, name, bases, attrs): 24 24 # If this isn't a subclass of Model, don't do anything special. 25 25 try: 26 if not filter(lambda b: issubclass(b, Model), bases): 26 for base in bases: 27 if issubclass(base, Model): 28 base = None 29 break 30 if base is not None: # We had a break. 27 31 return super(ModelBase, cls).__new__(cls, name, bases, attrs) 28 32 except NameError: 29 33 # 'Model' isn't defined yet, meaning we're looking at Django's own