Ticket #1077: empty_model_indenttation.patch

File empty_model_indenttation.patch, 779 bytes (added by i@…, 3 years ago)

Fixing patch

  • .py

    diff --git a/schemamigration.py b/schemamigration2.py
    index 379c2ca..1fdd4b0 100644
    old new class Command(DataCommand): 
    152152         
    153153        # So, what's in this file, then? 
    154154        file_contents = MIGRATION_TEMPLATE % { 
    155             "forwards": "\n".join(forwards_actions or ["pass"]), 
    156             "backwards": "\n".join(backwards_actions or ["pass"]), 
     155            "forwards": "\n".join(forwards_actions or [8 * " " + "pass"]), 
     156            "backwards": "\n".join(backwards_actions or [8 * " " + "pass"]), 
    157157            "frozen_models":  freezer.freeze_apps_to_string(apps_to_freeze), 
    158158            "complete_apps": apps_to_freeze and "complete_apps = [%s]" % (", ".join(map(repr, apps_to_freeze))) or "" 
    159159        }