# HG changeset patch # User Kim Alvefur # Date 1548455462 -3600 # Node ID 071aaaa5cb341219572dadd8a799fcf66e47d1a5 # Parent 330a937e085ea2d146e8b689f7b62875cba08781 mod_vcard_legacy: Allow disabling vcard conversion Once everyone has been migrated it might be nice to skip these checks diff -r 330a937e085e -r 071aaaa5cb34 plugins/mod_vcard_legacy.lua --- a/plugins/mod_vcard_legacy.lua Fri Jan 25 23:27:23 2019 +0100 +++ b/plugins/mod_vcard_legacy.lua Fri Jan 25 23:31:02 2019 +0100 @@ -307,6 +307,7 @@ 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 @@ session.log("info", "Failed to migrate vCard-temp to PEP: %s", err or "problem emptying 'vcard' store"); end end); +end