# HG changeset patch # User Matthew Wild # Date 1274465969 -3600 # Node ID fc7c693e094af9a173fe36e54ff68adbc9a2402e # Parent 5e5137057b5f54860e5f7d52394dd114546d7544 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. diff -r 5e5137057b5f -r fc7c693e094a plugins/mod_privacy.lua --- a/plugins/mod_privacy.lua Thu May 20 11:51:55 2010 +0100 +++ b/plugins/mod_privacy.lua Fri May 21 19:19:29 2010 +0100 @@ -160,26 +160,7 @@ 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