# HG changeset patch # User Kim Alvefur # Date 1526945564 -7200 # Node ID 0f9d5cfa84f9c7e2d1c64376400291d9bc30d0ec # Parent 5974c9da1391266652eaa46d76aaf2777c5a4900 util.pubsub: Also check for affiliation set on bare JID This fixes eg publishing from a full JID when the affiliation has been set on the bare JID, as would be common in XMPP. diff -r 5974c9da1391 -r 0f9d5cfa84f9 util/pubsub.lua --- a/util/pubsub.lua Mon May 21 00:44:37 2018 +0200 +++ b/util/pubsub.lua Tue May 22 01:32:44 2018 +0200 @@ -75,7 +75,8 @@ if actor == true then return true; end local node_obj = self.nodes[node]; - local node_aff = node_obj and node_obj.affiliations[actor]; + local node_aff = node_obj and (node_obj.affiliations[actor] + or node_obj.affiliations[self.config.normalize_jid(actor)]); local service_aff = self.affiliations[actor] or self.config.get_affiliation(actor, node, action) or "none";