hasTable('bruteforces'); if (!$exists) { $table = $this->table('bruteforces', [ 'signed' => false, 'collation' => 'utf8mb4_unicode_ci', ]); $table ->addColumn('user_ip', 'string', [ 'null' => false, 'length' => 45, ]) ->addColumn('username', 'string', [ 'null' => false, 'length' => 191, 'collation' => 'utf8mb4_unicode_ci' ]) ->addColumn('expiration', 'datetime', [ 'null' => false ]) ->addIndex('user_ip') ->addIndex('username') ->addIndex('expiration'); $table->create(); } } }