mirror of
https://github.com/django/django.git
synced 2025-10-24 22:26:08 +00:00
Fixed #21280 -- Don't generate empty migration files
This commit is contained in:
@@ -82,5 +82,6 @@ class Command(BaseCommand):
|
|||||||
open(init_path, "w").close()
|
open(init_path, "w").close()
|
||||||
# We just do this once per app
|
# We just do this once per app
|
||||||
directory_created[app_label] = True
|
directory_created[app_label] = True
|
||||||
|
migration_string = writer.as_string()
|
||||||
with open(writer.path, "wb") as fh:
|
with open(writer.path, "wb") as fh:
|
||||||
fh.write(writer.as_string())
|
fh.write(migration_string)
|
||||||
|
|||||||
Reference in New Issue
Block a user