summaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorGit'Fellow <12234510+solracsf@users.noreply.github.com>2024-01-17 21:33:26 +0100
committerGitHub <noreply@github.com>2024-01-17 21:33:26 +0100
commit328d9c661962e48fd5f66c4d2005cbe9113a198d (patch)
tree84c55675a018e0db027b9d702e94367cc08ef349 /apps
parent448dc1530f944e93516623a09a7229251fcd713f (diff)
parent47e715e1cb966fa1e23ab1525ceb5fcae133af4a (diff)
downloadnextcloud-server-328d9c661962e48fd5f66c4d2005cbe9113a198d.tar.gz
nextcloud-server-328d9c661962e48fd5f66c4d2005cbe9113a198d.zip
Merge pull request #42778 from nextcloud/backport/42067/stable27
[stable27] Fix some silent share bugs
Diffstat (limited to 'apps')
-rw-r--r--apps/files_sharing/src/views/SharingDetailsTab.vue10
-rw-r--r--apps/files_sharing/src/views/SharingTab.vue13
2 files changed, 13 insertions, 10 deletions
diff --git a/apps/files_sharing/src/views/SharingDetailsTab.vue b/apps/files_sharing/src/views/SharingDetailsTab.vue
index 580d24eae58..67bfac3e74c 100644
--- a/apps/files_sharing/src/views/SharingDetailsTab.vue
+++ b/apps/files_sharing/src/views/SharingDetailsTab.vue
@@ -398,9 +398,13 @@ export default {
|| !!this.share.password
},
async set(enabled) {
- // TODO: directly save after generation to make sure the share is always protected
- this.share.password = enabled ? await GeneratePassword() : ''
- this.$set(this.share, 'newPassword', this.share.password)
+ if (enabled) {
+ this.share.password = await GeneratePassword()
+ this.$set(this.share, 'newPassword', this.share.password)
+ } else {
+ this.share.password = ''
+ this.$delete(this.share, 'newPassword')
+ }
},
},
/**
diff --git a/apps/files_sharing/src/views/SharingTab.vue b/apps/files_sharing/src/views/SharingTab.vue
index 4019a99dbe0..555a4de56ec 100644
--- a/apps/files_sharing/src/views/SharingTab.vue
+++ b/apps/files_sharing/src/views/SharingTab.vue
@@ -375,14 +375,13 @@ export default {
* @param {Function} resolve a function to execute after
*/
awaitForShare(share, resolve) {
- let listComponent = this.$refs.shareList
- // Only mail shares comes from the input, link shares
- // are managed internally in the SharingLinkList component
- if (share.type === this.SHARE_TYPES.SHARE_TYPE_EMAIL) {
- listComponent = this.$refs.linkShareList
- }
-
this.$nextTick(() => {
+ let listComponent = this.$refs.shareList
+ // Only mail shares comes from the input, link shares
+ // are managed internally in the SharingLinkList component
+ if (share.type === this.SHARE_TYPES.SHARE_TYPE_EMAIL) {
+ listComponent = this.$refs.linkShareList
+ }
const newShare = listComponent.$children.find(component => component.share === share)
if (newShare) {
resolve(newShare)