fix: remove stale idx_webhooks_token index from migration
The token column was dropped in a previous migration step (ALTER TABLE webhooks DROP COLUMN IF EXISTS token), but the CREATE INDEX referencing it still ran, causing migration failure on databases where the column was already removed.
This commit is contained in:
@@ -183,7 +183,6 @@ CREATE INDEX IF NOT EXISTS idx_bots_token ON bots(token);
|
|||||||
CREATE INDEX IF NOT EXISTS idx_bot_servers_bot ON bot_servers(bot_id);
|
CREATE INDEX IF NOT EXISTS idx_bot_servers_bot ON bot_servers(bot_id);
|
||||||
CREATE INDEX IF NOT EXISTS idx_slash_commands_server ON slash_commands(server_id, name);
|
CREATE INDEX IF NOT EXISTS idx_slash_commands_server ON slash_commands(server_id, name);
|
||||||
CREATE INDEX IF NOT EXISTS idx_webhooks_channel ON webhooks(channel_id);
|
CREATE INDEX IF NOT EXISTS idx_webhooks_channel ON webhooks(channel_id);
|
||||||
CREATE INDEX IF NOT EXISTS idx_webhooks_token ON webhooks(token);
|
|
||||||
|
|
||||||
-- Add token_hash column for secure webhook token storage
|
-- Add token_hash column for secure webhook token storage
|
||||||
ALTER TABLE webhooks ADD COLUMN IF NOT EXISTS token_hash VARCHAR(64);
|
ALTER TABLE webhooks ADD COLUMN IF NOT EXISTS token_hash VARCHAR(64);
|
||||||
|
|||||||
Reference in New Issue
Block a user