Mercurial > eldonilo > lightstring
changeset 46:f23e4741a7c5
Fix im plugin.
author | Emmanuel Gil Peyrot <linkmauve@linkmauve.fr> |
---|---|
date | Wed, 01 Feb 2012 00:38:01 +0100 |
parents | 063e31247e71 |
children | ea276b47c555 |
files | plugins/im.js |
diffstat | 1 files changed, 8 insertions(+), 7 deletions(-) [+] |
line wrap: on
line diff
--- a/plugins/im.js +++ b/plugins/im.js @@ -19,12 +19,13 @@ ////// //IM// ////// -Lightstring.stanza.message = { - normal: function(aTo, aSubject, aText) { - return "<message type='normal' to='"+aTo+"'><subject>"+aSubject+"</subject><body>"+aText+"</body></message>"; - }, - chat: function(aTo, aText) { - return "<message type='chat' to='"+aTo+"'><body>"+aText+"</body></message>"; +Lightstring.plugins['message'] = { + stanzas: { + normalMessage: function(aTo, aSubject, aText) { + return "<message type='normal' to='" + aTo + "'><subject>" + aSubject + "</subject><body>" + aText + "</body></message>"; + }, + chatMessage: function(aTo, aText) { + return "<message type='chat' to='" + aTo + "'><body>" + aText + "</body></message>"; + } } }; -