Skip to content

Commit

Permalink
fix(files_sharing): add missing subtitle on search for share recipients
Browse files Browse the repository at this point in the history
Signed-off-by: Luka Trovic <luka@nextcloud.com>
  • Loading branch information
luka-nextcloud committed Aug 2, 2024
1 parent ab550f1 commit 8434279
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions apps/files_sharing/src/components/SharingInput.vue
Original file line number Diff line number Diff line change
Expand Up @@ -438,17 +438,17 @@ export default {
* @return {object}
*/
formatForMultiselect(result) {
let subtitle
let subname
if (result.value.shareType === this.SHARE_TYPES.SHARE_TYPE_USER && this.config.shouldAlwaysShowUnique) {
subtitle = result.shareWithDisplayNameUnique ?? ''
subname = result.shareWithDisplayNameUnique ?? ''
} else if ((result.value.shareType === this.SHARE_TYPES.SHARE_TYPE_REMOTE
|| result.value.shareType === this.SHARE_TYPES.SHARE_TYPE_REMOTE_GROUP
) && result.value.server) {
subtitle = t('files_sharing', 'on {server}', { server: result.value.server })
subname = t('files_sharing', 'on {server}', { server: result.value.server })
} else if (result.value.shareType === this.SHARE_TYPES.SHARE_TYPE_EMAIL) {
subtitle = result.value.shareWith
subname = result.value.shareWith
} else {
subtitle = result.shareWithDescription ?? ''
subname = result.shareWithDescription ?? ''
}
return {
Expand All @@ -457,7 +457,7 @@ export default {
user: result.uuid || result.value.shareWith,
isNoUser: result.value.shareType !== this.SHARE_TYPES.SHARE_TYPE_USER,
displayName: result.name || result.label,
subtitle,
subname,
shareWithDisplayNameUnique: result.shareWithDisplayNameUnique || '',
...this.shareTypeToIcon(result.value.shareType),
}
Expand Down

0 comments on commit 8434279

Please sign in to comment.