From 86d18ae835716fddeacd401fcaa858c6a682ebab Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Wed, 10 Feb 2021 17:28:21 +0100 Subject: Show "Guest" instead of session hash for guests Signed-off-by: Joas Schilling --- lib/Controller/CallController.php | 2 +- src/components/CallView/shared/Video.vue | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/Controller/CallController.php b/lib/Controller/CallController.php index 19ec07389..3650494e7 100644 --- a/lib/Controller/CallController.php +++ b/lib/Controller/CallController.php @@ -113,7 +113,7 @@ class CallController extends AEnvironmentAwareController { } } } else { - $displayName = $guestNames[$participant->getAttendee()->getActorId()] ?? $displayName; + $displayName = $guestNames[$participant->getAttendee()->getActorId()] ?? ''; } $result[] = [ diff --git a/src/components/CallView/shared/Video.vue b/src/components/CallView/shared/Video.vue index acaec6009..d7d1fe9f8 100644 --- a/src/components/CallView/shared/Video.vue +++ b/src/components/CallView/shared/Video.vue @@ -279,6 +279,9 @@ export default { if (!participantName) { participantName = this.peerData.displayName + if (!participantName && this.peerData.actorType === 'guests') { + participantName = t('spreed', 'Guest') + } } return participantName -- cgit v1.2.3 From 591f8b2b3d9e207e92077b16b1d585fbeef3c021 Mon Sep 17 00:00:00 2001 From: Joas Schilling Date: Thu, 11 Feb 2021 07:58:08 +0100 Subject: Use ATTENDEE constants Signed-off-by: Joas Schilling --- src/components/CallView/shared/Video.vue | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/components/CallView/shared/Video.vue b/src/components/CallView/shared/Video.vue index d7d1fe9f8..3da309e81 100644 --- a/src/components/CallView/shared/Video.vue +++ b/src/components/CallView/shared/Video.vue @@ -100,6 +100,7 @@ import AccountCircle from 'vue-material-design-icons/AccountCircle' import VideoBottomBar from './VideoBottomBar' import Screen from './Screen' import { EventBus } from '../../../services/EventBus' +import { ATTENDEE } from '../../../constants' export default { @@ -240,7 +241,7 @@ export default { // Check data from participant list if (this.participant?.actorType) { - if (this.participant?.actorType === 'users' && this.participant?.actorId) { + if (this.participant?.actorType === ATTENDEE.ACTOR_TYPE.USERS && this.participant?.actorId) { return this.participant.actorId } @@ -249,7 +250,7 @@ export default { } // Fallback to CallController::getPeers() endpoint - if (this.peerData.actorType === 'users') { + if (this.peerData.actorType === ATTENDEE.ACTOR_TYPE.USERS) { return this.peerData.actorId } @@ -279,7 +280,7 @@ export default { if (!participantName) { participantName = this.peerData.displayName - if (!participantName && this.peerData.actorType === 'guests') { + if (!participantName && this.peerData.actorType === ATTENDEE.ACTOR_TYPE.GUESTS) { participantName = t('spreed', 'Guest') } } -- cgit v1.2.3