Software /
code /
prosody
Comparison
plugins/mod_pep.lua @ 8965:1cc5ea1df5ba
mod_pep: Move comment to a shorter line [luacheck]
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Fri, 06 Jul 2018 00:04:13 +0200 |
parent | 8728:41c959c5c84b |
child | 8966:9106e9286203 |
comparison
equal
deleted
inserted
replaced
8964:76780f37028d | 8965:1cc5ea1df5ba |
---|---|
170 module:hook("iq/bare/http://jabber.org/protocol/pubsub:pubsub", function(event) | 170 module:hook("iq/bare/http://jabber.org/protocol/pubsub:pubsub", function(event) |
171 local session, stanza = event.origin, event.stanza; | 171 local session, stanza = event.origin, event.stanza; |
172 local payload = stanza.tags[1]; | 172 local payload = stanza.tags[1]; |
173 | 173 |
174 if stanza.attr.type == 'set' and (not stanza.attr.to or jid_bare(stanza.attr.from) == stanza.attr.to) then | 174 if stanza.attr.type == 'set' and (not stanza.attr.to or jid_bare(stanza.attr.from) == stanza.attr.to) then |
175 payload = payload.tags[1]; | 175 payload = payload.tags[1]; -- <publish node='http://jabber.org/protocol/tune'> |
176 if payload and (payload.name == 'publish' or payload.name == 'retract') and payload.attr.node then -- <publish node='http://jabber.org/protocol/tune'> | 176 if payload and (payload.name == 'publish' or payload.name == 'retract') and payload.attr.node then |
177 local node = payload.attr.node; | 177 local node = payload.attr.node; |
178 payload = payload.tags[1]; | 178 payload = payload.tags[1]; |
179 if payload and payload.name == "item" then -- <item> | 179 if payload and payload.name == "item" then -- <item> |
180 local id = payload.attr.id or "1"; | 180 local id = payload.attr.id or "1"; |
181 payload.attr.id = id; | 181 payload.attr.id = id; |