|
@@ -241,8 +241,14 @@ function create_poltergeist_occupant(room, nick, name, avatar, status, context)
|
241
|
241
|
join:tag("password", { xmlns = MUC_NS }):text(room_password);
|
242
|
242
|
end
|
243
|
243
|
|
|
244
|
+ -- Update the nil call id to the initial call id for call flows.
|
244
|
245
|
local call_id = get_username(room, context.user.id);
|
245
|
|
- join_presence:tag("call_id"):text(get_username(room, context.user.id)):up();
|
|
246
|
+ join_presence:maptags(function (tag)
|
|
247
|
+ if tag.name == "call_id" then
|
|
248
|
+ return st.stanza("call_id"):text(call_id);
|
|
249
|
+ end
|
|
250
|
+ return tag;
|
|
251
|
+ end);
|
246
|
252
|
|
247
|
253
|
update_presence_identity(
|
248
|
254
|
join_presence,
|
|
@@ -356,6 +362,7 @@ function update_presence_tags(presence_stanza, status, call_details)
|
356
|
362
|
return st.stanza("call_cancel"):text("false");
|
357
|
363
|
end
|
358
|
364
|
end
|
|
365
|
+ return tag;
|
359
|
366
|
end);
|
360
|
367
|
|
361
|
368
|
return presence_stanza
|