summaryrefslogtreecommitdiff
path: root/django/db/models/base.py
diff options
context:
space:
mode:
Diffstat (limited to 'django/db/models/base.py')
-rw-r--r--django/db/models/base.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/django/db/models/base.py b/django/db/models/base.py
index c04a6affb7..9236207f94 100644
--- a/django/db/models/base.py
+++ b/django/db/models/base.py
@@ -41,7 +41,9 @@ class ModelBase(type):
# Build complete list of parents
for base in parents:
- if base is not Model:
+ # Things without _meta aren't functional models, so they're
+ # uninteresting parents.
+ if hasattr(base, '_meta'):
new_class._meta.parents.append(base)
new_class._meta.parents.extend(base._meta.parents)
@@ -139,7 +141,7 @@ class Model(object):
# There is a rather weird disparity here; if kwargs, it's set, then args
# overrides it. It should be one or the other; don't duplicate the work
# The reason for the kwargs check is that standard iterator passes in by
- # args, and nstantiation for iteration is 33% faster.
+ # args, and instantiation for iteration is 33% faster.
args_len = len(args)
if args_len > len(self._meta.fields):
# Daft, but matches old exception sans the err msg.