diff options
author | F. E Noel Nfebe <fenn25.fn@gmail.com> | 2024-07-09 14:44:03 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-07-09 14:44:03 +0100 |
commit | 19ab1ffd0b7a95430a9bd83d63ff5c52175c3280 (patch) | |
tree | 95dc66d088b35a055ba86f319387cae4ca4d814c /apps | |
parent | 2595e488fdd2bf6a59923f684b5ee47e2b0faa1d (diff) | |
parent | 710287f6c804987953053ba25dea364bbb2383be (diff) | |
download | nextcloud-server-19ab1ffd0b7a95430a9bd83d63ff5c52175c3280.tar.gz nextcloud-server-19ab1ffd0b7a95430a9bd83d63ff5c52175c3280.zip |
Merge pull request #46364 from nextcloud/backport/46321/stable28
[stable28] fix(SharingDetailsView): Prevent illegal unselection of read permissions
Diffstat (limited to 'apps')
-rw-r--r-- | apps/files_sharing/src/views/SharingDetailsTab.vue | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/apps/files_sharing/src/views/SharingDetailsTab.vue b/apps/files_sharing/src/views/SharingDetailsTab.vue index a1e9ac734e5..37be85c37d4 100644 --- a/apps/files_sharing/src/views/SharingDetailsTab.vue +++ b/apps/files_sharing/src/views/SharingDetailsTab.vue @@ -566,6 +566,9 @@ export default { // allowed to revoke it too (but not to grant it again). return (this.fileInfo.canDownload() || this.canDownload) }, + canRemoveReadPermission() { + return this.allowsFileDrop && this.share.type === this.SHARE_TYPES.SHARE_TYPE_LINK + }, // if newPassword exists, but is empty, it means // the user deleted the original password hasUnsavedPassword() { @@ -774,6 +777,10 @@ export default { this.setCustomPermissions = true } } + // Read permission required for share creation + if (!this.canRemoveReadPermission) { + this.hasRead = true + } }, handleCustomPermissions() { if (!this.isNewShare && (this.hasCustomPermissions || this.share.setCustomPermissions)) { |