diff --git a/database/migrations/2020_12_01_073200_add_indexes_to_likes_table.php b/database/migrations/2020_12_01_073200_add_indexes_to_likes_table.php new file mode 100644 index 000000000..1a1256fbb --- /dev/null +++ b/database/migrations/2020_12_01_073200_add_indexes_to_likes_table.php @@ -0,0 +1,34 @@ +index('profile_id', 'likes_profile_id_index'); + $table->index('status_id', 'likes_status_id_index'); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::table('likes', function (Blueprint $table) { + $table->dropIndex('likes_profile_id_index'); + $table->dropIndex('likes_status_id_index'); + }); + } +}