View file database/upgrades/20190816205614_delete_icq_and_skype_in_users.php

File size: 605B
<?php

use Phinx\Migration\AbstractMigration;

class DeleteIcqAndSkypeInUsers extends AbstractMigration
{
    /**
     * Migrate Up.
     */
    public function up()
    {
        $table = $this->table('users');
        $table->removeColumn('icq')
            ->removeColumn('skype')
            ->save();
    }

    /**
     * Migrate Down.
     */
    public function down()
    {
        $table = $this->table('users');
        $table->addColumn('icq', 'string', ['limit' => 10, 'null' => true])
            ->addColumn('skype', 'string', ['limit' => 32, 'null' => true])
            ->save();
    }
}