From 645634ba63f4a315c2c9b9a6c5eab2393ed60953 Mon Sep 17 00:00:00 2001 From: Hannah Eslinger Date: Thu, 4 Jan 2024 13:03:02 -0700 Subject: [PATCH] Fix formatting --- seed/migrations/0212_move_filtergroup_labels.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/seed/migrations/0212_move_filtergroup_labels.py b/seed/migrations/0212_move_filtergroup_labels.py index 75f7eebb47..a676c58dbc 100644 --- a/seed/migrations/0212_move_filtergroup_labels.py +++ b/seed/migrations/0212_move_filtergroup_labels.py @@ -2,6 +2,7 @@ from django.db import migrations + def move_filter_groups(apps, schema_editor): FilterGroup = apps.get_model('seed', 'FilterGroup') for filter_group in FilterGroup.objects.all(): @@ -12,6 +13,7 @@ def move_filter_groups(apps, schema_editor): elif filter_group.labels.exists() and filter_group.label_logic == 2: # exclude filter_group.exclude_labels.set(filter_group.labels.all()) + def move_filter_groups_back(apps, schema_editor): # if the filter group only has one set of labels, we can move those back FilterGroup = apps.get_model('seed', 'FilterGroup') @@ -29,6 +31,7 @@ def move_filter_groups_back(apps, schema_editor): filter_group.label_logic = 2 filter_group.save() + class Migration(migrations.Migration): dependencies = [