Skip to content

Instantly share code, notes, and snippets.

@ricardoaugusto
Created April 22, 2020 20:27
Show Gist options
  • Save ricardoaugusto/5b9bea9863df43fe33cfebda0c6c5a07 to your computer and use it in GitHub Desktop.
Save ricardoaugusto/5b9bea9863df43fe33cfebda0c6c5a07 to your computer and use it in GitHub Desktop.
Laravel Restore Table
public function down()
{
(new AnotherMigration)->up();
}
@ricardoaugusto
Copy link
Author

A great tip from @contrerasojuanc. Useful when you need to restore a table when php artisan migrate:rollback without having to type all fields of the former table structure.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment