|
@@ -1159,8 +1159,18 @@ export default class ChatRoom extends Listenable {
|
1159
|
1159
|
this.eventEmitter.emit(XMPPEvents.PRIVATE_MESSAGE_RECEIVED,
|
1160
|
1160
|
from, txt, this.myroomjid, stamp);
|
1161
|
1161
|
} else if (type === 'groupchat') {
|
|
1162
|
+ const nickEl = $(msg).find('>nick');
|
|
1163
|
+ let nick;
|
|
1164
|
+
|
|
1165
|
+ if (nickEl.length > 0) {
|
|
1166
|
+ nick = nickEl.text();
|
|
1167
|
+ }
|
|
1168
|
+
|
|
1169
|
+ // we will fire explicitly that this is a guest(isGuest:true) to the conference
|
|
1170
|
+ // informing that this is probably a message from a guest to the conference (visitor)
|
|
1171
|
+ // a message with explicit name set
|
1162
|
1172
|
this.eventEmitter.emit(XMPPEvents.MESSAGE_RECEIVED,
|
1163
|
|
- from, txt, this.myroomjid, stamp);
|
|
1173
|
+ from, txt, this.myroomjid, stamp, nick, Boolean(nick));
|
1164
|
1174
|
}
|
1165
|
1175
|
}
|
1166
|
1176
|
}
|