From 4bc0b362f9d07dd8291c9e732a6a03b76b4a9a98 Mon Sep 17 00:00:00 2001 From: Nasr Date: Fri, 24 Jan 2025 14:54:08 +0700 Subject: [PATCH] fix: new enum diff --- crates/torii/sqlite/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/torii/sqlite/src/lib.rs b/crates/torii/sqlite/src/lib.rs index b2585b82bc..6697e77cc6 100644 --- a/crates/torii/sqlite/src/lib.rs +++ b/crates/torii/sqlite/src/lib.rs @@ -948,7 +948,7 @@ fn add_columns_recursive( let sql_type = format!( "TEXT CONSTRAINT [{column_name}_check] CHECK([{column_name}] IN ({all_options}))" ); - if enum_diff.is_some() { + if enum_diff.is_some_and(|diff| diff != e) { // For upgrades, modify the existing option column to add the new options to the // CHECK constraint We need to drop the old column and create a new // one with the new CHECK constraint