# HG changeset patch # User Kim Alvefur # Date 1742728516 -3600 # Node ID b30eaa74d35b97df7ad1e0ca4e52f45e366d7673 # Parent 4cfabfbb06919f85d52ab60bad52ac9fe1f52fca mod_storage_sql: Drop legacy index without confirmation to ease upgrades Deleting one index should be safe enough to do without requiring a explicitly upgrading during downtime. People had trouble with this. diff -r 4cfabfbb0691 -r b30eaa74d35b plugins/mod_storage_sql.lua --- a/plugins/mod_storage_sql.lua Sat Mar 22 11:53:15 2025 +0100 +++ b/plugins/mod_storage_sql.lua Sun Mar 23 12:15:16 2025 +0100 @@ -885,16 +885,12 @@ end end) if indices["prosody_index"] then - if apply_changes then - local success = engine:transaction(function () - return assert(engine:execute([[DROP INDEX "prosody_index";]])); - end); - if not success then - module:log("error", "Failed to delete obsolete index \"prosody_index\""); - return false; - end - else - changes = true; + local success = engine:transaction(function () + return assert(engine:execute([[DROP INDEX "prosody_index";]])); + end); + if not success then + module:log("error", "Failed to delete obsolete index \"prosody_index\""); + return false; end end end