<?php
defined('BASEPATH') OR exit('No direct script access allowed');

class Migration_Add_ban_expires_at_to_users extends CI_Migration {

    public function up() {
        $fields = array(
            'ban_expires_at' => array(
                'type' => 'DATETIME',
                'null' => TRUE,
                'default' => NULL,
                'after' => 'is_banned'
            )
        );
        $this->dbforge->add_column('users', $fields);
    }

    public function down() {
        $this->dbforge->drop_column('users', 'ban_expires_at');
    }
}
