mirror of
https://github.com/django/django.git
synced 2025-10-31 09:41:08 +00:00
[1.6.x] Replaced "not PY3" by "PY2", new in six 1.4.0.
Conflicts:
django/db/backends/oracle/base.py
django/db/backends/sqlite3/base.py
django/db/models/base.py
Backport of 365c3e8b from master.
This commit is contained in:
@@ -19,7 +19,7 @@ class MyModel(six.with_metaclass(CustomBaseModel, models.Model)):
|
||||
# This is done to ensure that for Python2 only, defining metaclasses
|
||||
# still does not fail to create the model.
|
||||
|
||||
if not six.PY3:
|
||||
if six.PY2:
|
||||
class MyModel(models.Model):
|
||||
"""Model subclass with a custom base using __metaclass__."""
|
||||
__metaclass__ = CustomBaseModel
|
||||
|
||||
Reference in New Issue
Block a user