aboutsummaryrefslogtreecommitdiffstats
path: root/tools/ejabberd2prosody.lua
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2021-10-13 10:04:11 +0100
committerMatthew Wild <mwild1@gmail.com>2021-10-13 10:04:11 +0100
commit21eeadecc7c94a07ea1ebdb1666dd40fa2ea8a9d (patch)
tree7105dd5199a4255a1abada9d4696726cb42031bc /tools/ejabberd2prosody.lua
parent1cfaaf66fd9e1ece3062a5f72f8f3654cbea1618 (diff)
downloadprosody-21eeadecc7c94a07ea1ebdb1666dd40fa2ea8a9d.tar.gz
prosody-21eeadecc7c94a07ea1ebdb1666dd40fa2ea8a9d.zip
ejabberd2prosody: Don't import disabled or empty passwords
Diffstat (limited to 'tools/ejabberd2prosody.lua')
-rwxr-xr-xtools/ejabberd2prosody.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/tools/ejabberd2prosody.lua b/tools/ejabberd2prosody.lua
index 8b95aaef..4d03a704 100755
--- a/tools/ejabberd2prosody.lua
+++ b/tools/ejabberd2prosody.lua
@@ -193,7 +193,9 @@ function muc_room(node, host, properties)
end
store._data.name = properties.title;
store._data.description = properties.description;
- store._data.password = properties.password;
+ if properties.password_protected ~= false and properties.password ~= "" then
+ store._data.password = properties.password;
+ end
store._data.moderated = (properties.moderated == "true") or nil;
store._data.members_only = (properties.members_only == "true") or nil;
store._data.persistent = (properties.persistent == "true") or nil;