aboutsummaryrefslogtreecommitdiffstats
path: root/plugins
diff options
context:
space:
mode:
authorKim Alvefur <zash@zash.se>2022-01-08 00:32:33 +0100
committerKim Alvefur <zash@zash.se>2022-01-08 00:32:33 +0100
commit475ab4aed299f4f1acb30a4e79e7f11a2b73cd4f (patch)
treeb89507d2ba34c244cae830802e67e4f7fbe72a4c /plugins
parent1fa49be0635db61582caef47bb822865eef103d5 (diff)
downloadprosody-475ab4aed299f4f1acb30a4e79e7f11a2b73cd4f.tar.gz
prosody-475ab4aed299f4f1acb30a4e79e7f11a2b73cd4f.zip
mod_bookmarks: Add option for disabling upgrade of legacy bookmarks
Might be nice to reduce amount of things happening on connect once all users has upgraded
Diffstat (limited to 'plugins')
-rw-r--r--plugins/mod_bookmarks.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/plugins/mod_bookmarks.lua b/plugins/mod_bookmarks.lua
index 141cab38..ef376104 100644
--- a/plugins/mod_bookmarks.lua
+++ b/plugins/mod_bookmarks.lua
@@ -414,7 +414,9 @@ module:hook("iq/bare/http://jabber.org/protocol/pubsub:pubsub", function (event)
return on_publish_legacy_pep(event);
end
end, 1);
-module:hook("resource-bind", migrate_legacy_bookmarks);
+if module:get_option_boolean("upgrade_legacy_bookmarks", true) then
+ module:hook("resource-bind", migrate_legacy_bookmarks);
+end
module:handle_items("pep-service", function (event)
local service = event.item.service;
module:hook_object_event(service.events, "node-created", on_node_created);