HummingBirdAnimeClient/migrations/20200430175135_anime_collection_cleanup.php

27 lines
486 B
PHP
Raw Permalink Normal View History

2022-03-03 18:19:02 -05:00
<?php declare(strict_types=1);
2020-04-30 15:33:16 -04:00
use Phinx\Migration\AbstractMigration;
class AnimeCollectionCleanup extends AbstractMigration
{
public function up()
{
if ($this->hasTable('genre_anime_set_link'))
{
$this->table('genre_anime_set_link')
->rename('anime_set_genre_link')
->update();
}
}
public function down()
{
if ($this->hasTable('anime_set_genre_link'))
{
$this->table('anime_set_genre_link')
->rename('genre_anime_set_link')
->update();
}
}
}