'json']; } public static function read(string $key, mixed $default = null): mixed { $setting = static::query()->find($key); return $setting === null ? $default : $setting->value; } public static function write(string $key, mixed $value): void { static::query()->updateOrCreate(['key' => $key], ['value' => $value]); } }