diff --git a/database/migrations/2018_04_17_012812_create_likes_table.php b/database/migrations/2018_04_17_012812_create_likes_table.php index 8c9d6492..ed20b960 100644 --- a/database/migrations/2018_04_17_012812_create_likes_table.php +++ b/database/migrations/2018_04_17_012812_create_likes_table.php @@ -19,6 +19,7 @@ class CreateLikesTable extends Migration $table->bigInteger('status_id')->unsigned(); // Flag to remove spammy profile_ids $table->boolean('flagged')->default(false); + $table->unique(['profile_id', 'status_id']); $table->timestamps(); }); }