Skip to content

Commit c31fd8d

Browse files
committed
Fix filtering our owner & current user from shares
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
1 parent 09d7854 commit c31fd8d

File tree

1 file changed

+9
-7
lines changed

1 file changed

+9
-7
lines changed

apps/files_sharing/src/components/SharingInput.vue

Lines changed: 9 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -306,14 +306,16 @@ export default {
306306
return arr
307307
}
308308
try {
309-
// filter out current user
310-
if (share.value.shareWith === getCurrentUser().uid) {
311-
return arr
312-
}
309+
if (share.value.shareType === this.SHARE_TYPES.SHARE_TYPE_USER) {
310+
// filter out current user
311+
if (share.value.shareWith === getCurrentUser().uid) {
312+
return arr
313+
}
313314
314-
// filter out the owner of the share
315-
if (this.reshare && share.value.shareWith === this.reshare.owner) {
316-
return arr
315+
// filter out the owner of the share
316+
if (this.reshare && share.value.shareWith === this.reshare.owner) {
317+
return arr
318+
}
317319
}
318320
319321
// filter out existing mail shares

0 commit comments

Comments
 (0)