mod_muc: Room subject should be sent only the newly joined occupant

Sat, 03 Jan 2009 18:46:52 +0500

author
Waqas Hussain <waqas20@gmail.com>
date
Sat, 03 Jan 2009 18:46:52 +0500
changeset 671
c7519f0c9a2c
parent 670
d5cf10b7fc44
child 672
7db1044d2fab
child 673
c9bc58e84e96

mod_muc: Room subject should be sent only the newly joined occupant

plugins/mod_muc.lua file | annotate | diff | comparison | revisions
--- a/plugins/mod_muc.lua	Sat Jan 03 18:45:51 2009 +0500
+++ b/plugins/mod_muc.lua	Sat Jan 03 18:46:52 2009 +0500
@@ -191,7 +191,7 @@
 					broadcast_presence(nil, to, room);
 					-- TODO send discussion history
 					if rooms_info:get(room, 'subject') then
-						broadcast_message(room, room, rooms_info:get(room, 'subject'), nil);
+						core_route_stanza(component, st.message({type='groupchat', from=room, to=from}):tag("subject"):text(rooms_info:get(room, 'subject')));
 					end
 				end
 			end

mercurial