Update migration

pull/4862/head
Daniel Supernault 3 years ago
parent c53894fe16
commit ef57d471e5
No known key found for this signature in database
GPG Key ID: 23740873EE6F76A1

@ -24,9 +24,17 @@ return new class extends Migration
public function down(): void public function down(): void
{ {
Schema::table('users', function (Blueprint $table) { Schema::table('users', function (Blueprint $table) {
if (Schema::hasColumn('users', 'has_roles')) {
$table->dropColumn('has_roles'); $table->dropColumn('has_roles');
$table->dropColumn('parent_id'); }
if (Schema::hasColumn('users', 'role_id')) {
$table->dropColumn('role_id'); $table->dropColumn('role_id');
}
if (Schema::hasColumn('users', 'parent_id')) {
$table->dropColumn('parent_id');
}
}); });
} }
}; };

Loading…
Cancel
Save