Fixed #17627 -- Renamed util.py files to utils.py

Thanks PaulM for the suggestion and Luke Granger-Brown and
Wiktor Kołodziej for the initial patch.
This commit is contained in:
Tim Graham 2013-09-16 12:52:05 -04:00
parent 8d29005524
commit 18ffdb1772
58 changed files with 111 additions and 84 deletions

View file

@ -7,7 +7,7 @@ circular import difficulties.
"""
from __future__ import unicode_literals
from django.db.backends import util
from django.db.backends import utils
from django.utils import six
from django.utils import tree
@ -194,7 +194,7 @@ def deferred_class_factory(model, attrs):
# name using the passed in attrs. It's OK to reuse an existing class
# object if the attrs are identical.
name = "%s_Deferred_%s" % (model.__name__, '_'.join(sorted(list(attrs))))
name = util.truncate_name(name, 80, 32)
name = utils.truncate_name(name, 80, 32)
overrides = dict((attr, DeferredAttribute(attr, model)) for attr in attrs)
overrides["Meta"] = Meta