<?php namespace RainLab\User\Updates;

use Schema;
use October\Rain\Database\Updates\Migration;

class UsersAddPermission2 extends Migration
{
    public function up()
    {
        Schema::table('users', function($table)
        {
            $table->text('permission2')->nullable();
        });
    }

    public function down()
    {
        if (Schema::hasColumn('users', 'permission2')) {
            Schema::table('users', function($table)
            {
                $table->dropColumn('permission2');
            });
        }
    }
}
