Skip to content

Commit

Permalink
Move migrations.AddIndex() in migrations.SeparateDatabaseAndState(sta…
Browse files Browse the repository at this point in the history
…te_oprations=[..])
  • Loading branch information
memclutter committed Nov 13, 2022
1 parent 966ad0d commit 10f8c74
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions polls/migrations/0002_question_polls_quest_pub_dat_ca81de_idx.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,12 @@ class Migration(migrations.Migration):
]

operations = [
migrations.AddIndex(
model_name='question',
index=models.Index(fields=['-pub_date'], name='polls_quest_pub_dat_ca81de_idx'),
migrations.SeparateDatabaseAndState(
state_operations=[
migrations.AddIndex(
model_name='question',
index=models.Index(fields=['-pub_date'], name='polls_quest_pub_dat_ca81de_idx'),
),
]
),
]

0 comments on commit 10f8c74

Please sign in to comment.