Commit 6cdd92ef authored by Benjamin REIS's avatar Benjamin REIS
Browse files

add participant devices on participant added notifications

parent 532020bb
......@@ -115,10 +115,21 @@ string LocalConferenceEventHandlerPrivate::createNotifyParticipantAdded (const A
ConferenceType confInfo = ConferenceType(entity);
UsersType users;
confInfo.setUsers(users);
UserType user = UserType();
UserRolesType roles;
UserType::EndpointSequence endpoints;
shared_ptr<Participant> p = conf->findParticipant(addr);
if (p) {
for (const auto &device : p->getPrivate()->getDevices()) {
const string &gruu = device.getGruu().asStringUriOnly();
EndpointType endpoint = EndpointType();
endpoint.setEntity(gruu);
endpoint.setState("full");
user.getEndpoint().push_back(endpoint);
}
}
user.setRoles(roles);
user.setEntity(addr.asStringUriOnly());
user.getRoles()->getEntry().push_back("participant");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment