From 1fe3e2754ac0de82ea56cb911f74a52edc59ea29 Mon Sep 17 00:00:00 2001 From: Kim Alvefur Date: Fri, 25 Jan 2019 23:31:02 +0100 Subject: mod_vcard_legacy: Allow disabling vcard conversion Once everyone has been migrated it might be nice to skip these checks --- plugins/mod_vcard_legacy.lua | 2 ++ 1 file changed, 2 insertions(+) diff --git a/plugins/mod_vcard_legacy.lua b/plugins/mod_vcard_legacy.lua index 633b7729..7dff1d09 100644 --- a/plugins/mod_vcard_legacy.lua +++ b/plugins/mod_vcard_legacy.lua @@ -307,6 +307,7 @@ module:hook("pre-presence/full", inject_xep153, 1); module:hook("pre-presence/bare", inject_xep153, 1); module:hook("pre-presence/host", inject_xep153, 1); +if module:get_option_boolean("upgrade_legacy_vcards", true) then module:hook("resource-bind", function (event) local session = event.session; local username = session.username; @@ -331,3 +332,4 @@ module:hook("resource-bind", function (event) session.log("info", "Failed to migrate vCard-temp to PEP: %s", err or "problem emptying 'vcard' store"); end end); +end -- cgit v1.2.3