From eac0f47831fe0212b2fac99935961301dd5609f5 Mon Sep 17 00:00:00 2001 From: Maxence Lange Date: Wed, 23 Jun 2021 12:12:53 -0100 Subject: [PATCH] hide personal circle from the sharedWithMe Signed-off-by: Maxence Lange --- apps/files_sharing/src/utils/SharedWithMe.js | 32 ++++++++++++++------ 1 file changed, 22 insertions(+), 10 deletions(-) diff --git a/apps/files_sharing/src/utils/SharedWithMe.js b/apps/files_sharing/src/utils/SharedWithMe.js index 400bb8010f196..1959cd30222f1 100644 --- a/apps/files_sharing/src/utils/SharedWithMe.js +++ b/apps/files_sharing/src/utils/SharedWithMe.js @@ -34,16 +34,28 @@ const shareWithTitle = function(share) { { escape: false } ) } else if (share.type === OC.Share.SHARE_TYPE_CIRCLE) { - return t( - 'files_sharing', - 'Shared with you and {circle} by {owner}', - { - circle: share.shareWithDisplayName, - owner: share.ownerDisplayName, - }, - undefined, - { escape: false } - ) + if (share.shareWithDisplayName === ' ') { + return t( + 'files_sharing', + 'Shared with you by {owner}', + { + owner: share.ownerDisplayName, + }, + undefined, + { escape: false } + ) + } else { + return t( + 'files_sharing', + 'Shared with you and {circle} by {owner}', + { + circle: share.shareWithDisplayName, + owner: share.ownerDisplayName, + }, + undefined, + { escape: false } + ) + } } else if (share.type === OC.Share.SHARE_TYPE_ROOM) { if (share.shareWithDisplayName) { return t(