Closed ollyollyollyltd closed 6 months ago
We don't use down migrations in any package / project.
99.9% of the time you are not gonna use a down migration and you’re probably never testing them. Just write an up migration if you want to drop a column again. 👍
Okay, fair enough.
Kind regards,
Olly Cross OllyOllyOlly Ltd
On Tue, Apr 30, 2024 at 12:27 PM Niels Vanpachtenbeke < @.***> wrote:
We don't use down migrations in any package / project.
99.9% of the time you are not gonna use a down migration and you’re probably never testing them. Just write an up migration if you want to drop a column again. 👍
— Reply to this email directly, view it on GitHub https://github.com/spatie/laravel-medialibrary/pull/3599#issuecomment-2085041939, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABGSAV3HO4DVRLVJKSBJCDTY7552PAVCNFSM6AAAAABG76D5AGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDAOBVGA2DCOJTHE . You are receiving this because you authored the thread.Message ID: @.***>
This package publishes a migration to create the
media
table, but it only has anup
method.This means that if the migration is rolled back, and then migrated again, the migration will fail as the
media
table already exists.This pull request adds a simple
down
method to the migration to drop themedia
table.