Changeset

80:ae77d9c41f4f

clix.archive: The world doesn't revolve around us.
author Kim Alvefur <zash@zash.se>
date Thu, 28 Jun 2012 11:32:08 +0200
parents 79:a19ccb8f1ef9
children 81:e87f4d0b1a80
files clix/archive.lua
diffstat 1 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/clix/archive.lua	Mon Jun 25 23:57:54 2012 +0200
+++ b/clix/archive.lua	Thu Jun 28 11:32:08 2012 +0200
@@ -17,9 +17,10 @@
 		-- TODO Roster lookup
 		-- TODO Timestamp
 		local a = m.attr;
-		if bare_jid(a.from) == selfjid then
+		if a.to and bare_jid(a.to) ~= selfjid then
 			print("To ".. bare_jid(a.to));
-		else
+		end
+		if a.from and bare_jid(a.from) ~= selfjid then
 			print("From ".. bare_jid(a.from));
 		end
 		print(m:get_child_text"body");