Skip to content

Commit 730874d

Browse files
committed
making return logic clearer
1 parent 09f9e0b commit 730874d

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

piccolo/apps/migrations/commands/forwards.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -100,15 +100,13 @@ async def run_forwards(
100100
if not response.success:
101101
return response
102102

103+
return MigrationResult(success=True)
104+
103105
else:
104106
manager = ForwardsMigrationManager(
105107
app_name=app_name, migration_id=migration_id, fake=fake
106108
)
107-
response = await manager.run()
108-
if not response.success:
109-
return response
110-
111-
return MigrationResult(success=True)
109+
return await manager.run()
112110

113111

114112
async def forwards(

0 commit comments

Comments
 (0)