mirror of
https://github.com/django/django.git
synced 2025-06-16 00:49:12 +00:00
magic-removal: Changed inner-class name in models from MANIPULATOR to Manipulator
git-svn-id: http://code.djangoproject.com/svn/django/branches/magic-removal@2096 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
parent
43d6bef62b
commit
387f453db5
@ -26,11 +26,12 @@ class ManipulatorDescriptor(object):
|
|||||||
raise "Manipulator can not be accessed via instance"
|
raise "Manipulator can not be accessed via instance"
|
||||||
else:
|
else:
|
||||||
if not self.man:
|
if not self.man:
|
||||||
# Create a class which inherits from the MANIPULATOR class given in the class,
|
# Create a class that inherits from the "Manipulator" class
|
||||||
# and the appropriate automatic manipulator,
|
# given in the model class (if specified) and the automatic
|
||||||
|
# manipulator.
|
||||||
bases = [self.base]
|
bases = [self.base]
|
||||||
if hasattr(type, 'MANIPULATOR'):
|
if hasattr(type, 'Manipulator'):
|
||||||
bases = [type.MANIPULATOR] + bases
|
bases = [type.Manipulator] + bases
|
||||||
self.man = types.ClassType(self.name, tuple(bases), {})
|
self.man = types.ClassType(self.name, tuple(bases), {})
|
||||||
self.man._prepare(type)
|
self.man._prepare(type)
|
||||||
return self.man
|
return self.man
|
||||||
|
Loading…
x
Reference in New Issue
Block a user