aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Wild <mwild1@gmail.com>2010-05-21 19:19:29 +0100
committerMatthew Wild <mwild1@gmail.com>2010-05-21 19:19:29 +0100
commit7398bee580883ce652fa3de579daa483caac5bfa (patch)
tree6fa70534fbed462c8339016fe15842fd5f4e1c0d
parent58ceb41a9495c734a9ff3fa9eece8ef6fc29ecbe (diff)
downloadprosody-7398bee580883ce652fa3de579daa483caac5bfa.tar.gz
prosody-7398bee580883ce652fa3de579daa483caac5bfa.zip
mod_privacy: Remove validation that checks a roster group you block actually exists - it would be time-consuming on large rosters, and isn't important (or correct?) anyway.
-rw-r--r--plugins/mod_privacy.lua21
1 files changed, 1 insertions, 20 deletions
diff --git a/plugins/mod_privacy.lua b/plugins/mod_privacy.lua
index 77b4dd12..5a25f9a5 100644
--- a/plugins/mod_privacy.lua
+++ b/plugins/mod_privacy.lua
@@ -160,26 +160,7 @@ function createOrReplaceList (privacy_lists, origin, stanza, name, entries, rost
end
end
- if tmp.type == "group" then
- local found = false;
- local roster = load_roster(origin.username, origin.host);
- for jid,item in pairs(roster) do
- if item.groups ~= nil then
- for group in pairs(item.groups) do
- if group == tmp.value then
- found = true;
- break;
- end
- end
- if found == true then
- break;
- end
- end
- end
- if found == false then
- return {"cancel", "item-not-found", "Specifed roster group not existing."};
- end
- elseif tmp.type == "subscription" then
+ if tmp.type == "subscription" then
if tmp.value ~= "both" and
tmp.value ~= "to" and
tmp.value ~= "from" and