mirror of
https://github.com/nextcloud/talk-android
synced 2025-06-20 03:59:35 +01:00
Fix joining a call
Signed-off-by: Joas Schilling <coding@schilljs.com>
This commit is contained in:
parent
335afb03dd
commit
dde79b5671
@ -2044,11 +2044,11 @@ public class CallController extends BaseController {
|
|||||||
nick = getPeerConnectionWrapperForSessionIdAndType(session, videoStreamType, false).getNick();
|
nick = getPeerConnectionWrapperForSessionIdAndType(session, videoStreamType, false).getNick();
|
||||||
}
|
}
|
||||||
|
|
||||||
String userId;
|
String userId = "";
|
||||||
if (hasMCU) {
|
if (hasMCU) {
|
||||||
userId = webSocketClient.getUserIdForSession(session);
|
userId = webSocketClient.getUserIdForSession(session);
|
||||||
} else {
|
} else if (participantMap.get(session).getActorType() == Participant.ActorType.USERS) {
|
||||||
userId = participantMap.get(session).getUserId();
|
userId = participantMap.get(session).getActorId();
|
||||||
}
|
}
|
||||||
|
|
||||||
String urlForAvatar;
|
String urlForAvatar;
|
||||||
|
@ -399,16 +399,22 @@ public class MagicWebSocketInstance extends WebSocketListener {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public String getDisplayNameForSession(String session) {
|
public String getDisplayNameForSession(String session) {
|
||||||
if (usersHashMap.containsKey(session)) {
|
Participant participant = usersHashMap.get(session);
|
||||||
return usersHashMap.get(session).getDisplayName();
|
if (participant != null) {
|
||||||
|
if (participant.getDisplayName() != null) {
|
||||||
|
return participant.getDisplayName();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return NextcloudTalkApplication.Companion.getSharedApplication().getString(R.string.nc_nick_guest);
|
return NextcloudTalkApplication.Companion.getSharedApplication().getString(R.string.nc_nick_guest);
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getUserIdForSession(String session) {
|
public String getUserIdForSession(String session) {
|
||||||
if (usersHashMap.containsKey(session)) {
|
Participant participant = usersHashMap.get(session);
|
||||||
return usersHashMap.get(session).getUserId();
|
if (participant != null) {
|
||||||
|
if (participant.getActorType() == Participant.ActorType.USERS) {
|
||||||
|
return participant.getActorId();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return "";
|
return "";
|
||||||
|
Loading…
Reference in New Issue
Block a user