Fixed #21280 -- Don't generate empty migration files

This commit is contained in:
Javed Khan 2013-10-17 16:24:20 +05:30 committed by Tim Graham
parent 7f508a3673
commit a921f06345
1 changed files with 2 additions and 1 deletions

View File

@ -82,5 +82,6 @@ class Command(BaseCommand):
open(init_path, "w").close()
# We just do this once per app
directory_created[app_label] = True
migration_string = writer.as_string()
with open(writer.path, "wb") as fh:
fh.write(writer.as_string())
fh.write(migration_string)