From dc99eac19cd20304894259ecdae218953d177b9e Mon Sep 17 00:00:00 2001 From: Corey Oordt Date: Wed, 13 May 2015 16:20:58 -0500 Subject: [PATCH] Fixes potential double imports in dev and test servers --- categories/migration.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/categories/migration.py b/categories/migration.py index 290d6de..d9af11f 100644 --- a/categories/migration.py +++ b/categories/migration.py @@ -35,11 +35,14 @@ def drop_field(app_name, model_name, field_name): schema_editor.remove_field(model, field) -def migrate_app(sender, app_config, verbosity=False, *args, **kwargs): +def migrate_app(sender, *args, **kwargs): """ Migrate all models of this app registered """ from .registration import registry + if 'app_config' not in kwargs: + return + app_config = kwargs['app_config'] app_name = app_config.label