increments('id'); $table->integer('user_id')->index(); $table->integer('favouritable_id'); $table->string('favouritable_type', 100); $table->timestamps(); $table->index(['favouritable_id', 'favouritable_type'], 'favouritable_index'); }); } /** * Reverse the migrations. */ public function down(): void { Schema::dropIfExists('favourites'); } };