1
0
mirror of https://github.com/django/django.git synced 2025-10-30 17:16:10 +00:00

Fixed #22918 -- Fixed SeparateDatabaseAndState crash

This commit is contained in:
Dave Hall
2014-09-01 10:30:00 +01:00
committed by Tim Graham
parent 03c1a6cb80
commit e03b7940e5
2 changed files with 35 additions and 2 deletions

View File

@@ -24,7 +24,7 @@ class SeparateDatabaseAndState(Operation):
for database_operation in self.database_operations:
to_state = from_state.clone()
database_operation.state_forwards(app_label, to_state)
database_operation.database_forwards(self, app_label, schema_editor, from_state, to_state)
database_operation.database_forwards(app_label, schema_editor, from_state, to_state)
from_state = to_state
def database_backwards(self, app_label, schema_editor, from_state, to_state):
@@ -36,7 +36,7 @@ class SeparateDatabaseAndState(Operation):
dbop.state_forwards(app_label, to_state)
from_state = base_state.clone()
database_operation.state_forwards(app_label, from_state)
database_operation.database_backwards(self, app_label, schema_editor, from_state, to_state)
database_operation.database_backwards(app_label, schema_editor, from_state, to_state)
def describe(self):
return "Custom state/database change combination"