hasTable('ngb_leases')) { return null; } $t = $schema->createTable('ngb_leases'); $t->addColumn('id', Types::STRING, ['notnull' => true, 'length' => 32]); $t->addColumn('name', Types::STRING, ['notnull' => true, 'length' => 128]); $t->addColumn('mode', Types::STRING, ['notnull' => true, 'length' => 1]); $t->addColumn('expires_at', Types::BIGINT, ['notnull' => true, 'unsigned' => true]); $t->setPrimaryKey(['id']); $t->addIndex(['name'], 'ngb_leases_name'); return $schema; } }