Changeset

146:ae85457eca8e

clix.archive: Skip printing body-less messages These are more and more common in archives, e.g. receipts, errors, OMEMO etc.
author Kim Alvefur <zash@zash.se>
date Mon, 08 Feb 2021 22:56:45 +0100
parents 145:6e05b25c2669
children 147:0bc82a318c45
files clix/archive.lua
diffstat 1 files changed, 1 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/clix/archive.lua	Mon Nov 23 23:52:31 2020 +0100
+++ b/clix/archive.lua	Mon Feb 08 22:56:45 2021 +0100
@@ -17,6 +17,7 @@
 	local function print_message(i)
 		-- TODO Roster lookup
 		local m = i.message;
+		if not m:get_child("body") then return end
 		local a = m.attr;
 		if i.stamp then
 			print(os.date("%Y-%m-%d %H:%M:%S", i.stamp));