From 22e79fc7613b8c7b00d6f45484277e53a075d69a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Granh=C3=A3o?= <32176319+danielgranhao@users.noreply.github.com> Date: Mon, 13 Jan 2025 15:07:19 +0000 Subject: [PATCH] Fix migrations ordering (#656) --- lib/core/src/persist/migrations.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/lib/core/src/persist/migrations.rs b/lib/core/src/persist/migrations.rs index 4884c42..b5d4f6d 100644 --- a/lib/core/src/persist/migrations.rs +++ b/lib/core/src/persist/migrations.rs @@ -222,10 +222,6 @@ pub(crate) fn current_migrations() -> Vec<&'static str> { ALTER TABLE send_swaps ADD COLUMN timeout_block_height INTEGER NOT NULL DEFAULT 0; ", " - ALTER TABLE receive_swaps ADD COLUMN destination_pubkey TEXT; - ALTER TABLE send_swaps ADD COLUMN destination_pubkey TEXT; - ", - " ALTER TABLE receive_swaps ADD COLUMN version INTEGER NOT NULL DEFAULT 0; ALTER TABLE send_swaps ADD COLUMN version INTEGER NOT NULL DEFAULT 0; ALTER TABLE chain_swaps ADD COLUMN version INTEGER NOT NULL DEFAULT 0; @@ -248,5 +244,9 @@ pub(crate) fn current_migrations() -> Vec<&'static str> { WHERE id = NEW.id; END; ", + " + ALTER TABLE receive_swaps ADD COLUMN destination_pubkey TEXT; + ALTER TABLE send_swaps ADD COLUMN destination_pubkey TEXT; + ", ] }