Skip to content
This repository was archived by the owner on Nov 30, 2022. It is now read-only.

Commit 713da8c

Browse files
author
Tyler King
authored
Added check for if soft delete (#642)
* Added check for if soft delete is already enabled on users table for the migration * StyleCI fix
1 parent 5e51672 commit 713da8c

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/ShopifyApp/resources/database/migrations/2020_01_29_230905_create_shops_table.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,9 @@ public function up(): void
1919
$table->boolean('shopify_freemium')->default(false);
2020
$table->integer('plan_id')->unsigned()->nullable();
2121

22-
$table->softDeletes();
22+
if (! Schema::hasColumn('users', 'deleted_at')) {
23+
$table->softDeletes();
24+
}
2325

2426
$table->foreign('plan_id')->references('id')->on('plans');
2527
});

0 commit comments

Comments
 (0)