From 6967b6bdc52cc36a9fd8ad75e545f69f84e10ff7 Mon Sep 17 00:00:00 2001 From: Jeremy Stretch Date: Wed, 21 Feb 2018 12:00:38 -0500 Subject: [PATCH] Fixes #1892: Removed convenience function from an old migration (see #632) to fix database error on extras/0009_topologymap_type --- .../0004_topologymap_change_comma_to_semicolon.py | 9 --------- 1 file changed, 9 deletions(-) diff --git a/netbox/extras/migrations/0004_topologymap_change_comma_to_semicolon.py b/netbox/extras/migrations/0004_topologymap_change_comma_to_semicolon.py index bf2711c43..ee838046d 100644 --- a/netbox/extras/migrations/0004_topologymap_change_comma_to_semicolon.py +++ b/netbox/extras/migrations/0004_topologymap_change_comma_to_semicolon.py @@ -4,14 +4,6 @@ from __future__ import unicode_literals from django.db import migrations, models -from extras.models import TopologyMap - - -def commas_to_semicolons(apps, schema_editor): - for tm in TopologyMap.objects.filter(device_patterns__contains=','): - tm.device_patterns = tm.device_patterns.replace(',', ';') - tm.save() - class Migration(migrations.Migration): @@ -25,5 +17,4 @@ class Migration(migrations.Migration): name='device_patterns', field=models.TextField(help_text=b'Identify devices to include in the diagram using regular expressions, one per line. Each line will result in a new tier of the drawing. Separate multiple regexes within a line using semicolons. Devices will be rendered in the order they are defined.'), ), - migrations.RunPython(commas_to_semicolons), ]