From 61efe5330e3a1f8111973dbbb055d1d3275adc15 Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Sat, 18 Aug 2018 14:38:18 +0100 Subject: mod_pep: Simplify code --- plugins/mod_pep.lua | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'plugins') diff --git a/plugins/mod_pep.lua b/plugins/mod_pep.lua index 50cf3ff1..0d52a2fd 100644 --- a/plugins/mod_pep.lua +++ b/plugins/mod_pep.lua @@ -253,8 +253,7 @@ end local function resend_last_item(jid, node, service) local ok, id, item = service:get_last_item(node, jid); - if not ok then return; end - if not id then return; end + if not (ok and id) then return; end service.config.broadcaster("items", node, { [jid] = true }, item); end -- cgit v1.2.3