Skip to content

Commit

Permalink
Update migration
Browse files Browse the repository at this point in the history
  • Loading branch information
daveearley committed Dec 18, 2024
1 parent 5e997d2 commit 83845a6
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,19 @@
public function up(): void
{
Schema::table('attendees', static function (Blueprint $table) {
if (Schema::hasColumn('attendees', 'notes')) {
return;
}
$table->text('notes')->nullable();
});
}

public function down(): void
{
Schema::table('attendees', static function (Blueprint $table) {
if (!Schema::hasColumn('attendees', 'notes')) {
return;
}
$table->dropColumn('notes');
});
}
Expand Down

0 comments on commit 83845a6

Please sign in to comment.