<?php
declare(strict_types=1);

use Celena\Core\Database\Blueprint;
use Celena\Core\Database\Connection;
use Celena\Core\Database\Schema;

return function (Schema $schema, Connection $conn): void {
    $schema->create('celena_options', function (Blueprint $t) {
        $t->id();
        $t->string('option_key', 191);
        $t->text('option_value')->nullable();
        $t->boolean('autoload')->default(true);
        $t->datetime('updated_at')->nullable();
        $t->unique('option_key');
        $t->index('autoload');
    });
};
