UNPKG

unleash-server

Version:

Unleash is an enterprise ready feature flag service. It provides different strategies for handling feature flags.

21 lines (20 loc) 674 B
"use strict"; exports.up = function (db, cb) { db.runSql(` DROP INDEX IF EXISTS idx_ai_chats_user_id; DROP TABLE IF EXISTS ai_chats; `, cb); }; exports.down = function (db, cb) { db.runSql(` CREATE TABLE IF NOT EXISTS ai_chats ( id BIGSERIAL PRIMARY KEY NOT NULL, user_id INTEGER NOT NULL REFERENCES users(id) ON DELETE CASCADE, created_at TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT now(), messages JSONB NOT NULL ); CREATE INDEX IF NOT EXISTS idx_ai_chats_user_id ON ai_chats(user_id); `, cb); }; //# sourceMappingURL=20241220102327-drop-ai-chats.js.map