From bad627119cb45a209a8b38af6ffb5b89921fcdc9 Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Fri, 3 Jan 2025 20:36:06 -0700 Subject: [PATCH] Fix migration --- .../2024_05_20_062706_update_group_posts_table.php | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/database/migrations/2024_05_20_062706_update_group_posts_table.php b/database/migrations/2024_05_20_062706_update_group_posts_table.php index 48ecde38b..828727395 100644 --- a/database/migrations/2024_05_20_062706_update_group_posts_table.php +++ b/database/migrations/2024_05_20_062706_update_group_posts_table.php @@ -2,6 +2,7 @@ use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; +use Illuminate\Support\Facades\DB; use Illuminate\Support\Facades\Schema; return new class extends Migration @@ -12,7 +13,9 @@ return new class extends Migration public function up(): void { Schema::table('group_posts', function (Blueprint $table) { - $table->dropUnique(['status_id']); + if (DB::getDriverName() === 'sqlite') { + $table->dropUnique(['status_id']); + } $table->dropColumn('status_id'); $table->dropColumn('reply_child_id'); $table->dropColumn('in_reply_to_id');