Changeset

2000:c31aa53348b8

mod_vcard: Fixed traceback on attempt to set vcards by non-c2s sessions.
author Waqas Hussain <waqas20@gmail.com>
date Sun, 18 Oct 2009 06:55:00 +0500
parents 1999:05054e360d89
children 2001:2f73fe2b3edd
files plugins/mod_vcard.lua
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/mod_vcard.lua	Sun Oct 18 06:49:40 2009 +0500
+++ b/plugins/mod_vcard.lua	Sun Oct 18 06:55:00 2009 +0500
@@ -40,7 +40,7 @@
 				session.send(st.error_reply(stanza, "cancel", "item-not-found"));
 			end
 		elseif stanza.attr.type == "set" then
-			if not to or to == session.username.."@"..session.host then
+			if not to then
 				if datamanager.store(session.username, session.host, "vcard", st.preserialize(stanza.tags[1])) then
 					session.send(st.reply(stanza));
 				else