From 699cbeb2fcc0f6bbaa12234e965900a5b27d52d2 Mon Sep 17 00:00:00 2001
From: Christoph Wurst <christoph@winzerhof-wurst.at>
Date: Wed, 19 Feb 2020 13:30:42 +0100
Subject: Show the link password when it's set

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
Signed-off-by: npmbuildbot[bot] <npmbuildbot[bot]@users.noreply.github.com>
---
 apps/files_sharing/src/components/SharingEntryLink.vue | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

(limited to 'apps/files_sharing/src/components/SharingEntryLink.vue')

diff --git a/apps/files_sharing/src/components/SharingEntryLink.vue b/apps/files_sharing/src/components/SharingEntryLink.vue
index e2c1ec63364..c7771cc8104 100644
--- a/apps/files_sharing/src/components/SharingEntryLink.vue
+++ b/apps/files_sharing/src/components/SharingEntryLink.vue
@@ -298,6 +298,7 @@
 <script>
 import { generateUrl } from '@nextcloud/router'
 import axios from '@nextcloud/axios'
+import Vue from 'vue'
 
 import ActionButton from '@nextcloud/vue/dist/Components/ActionButton'
 import ActionCheckbox from '@nextcloud/vue/dist/Components/ActionCheckbox'
@@ -423,8 +424,8 @@ export default {
 			},
 			set: async function(enabled) {
 				// TODO: directly save after generation to make sure the share is always protected
-				this.share.password = enabled ? await this.generatePassword() : ''
-				this.share.newPassword = this.share.password
+				Vue.set(this.share, 'password', enabled ? await this.generatePassword() : '')
+				Vue.set(this.share, 'newPassword', this.share.password)
 			},
 		},
 
-- 
cgit v1.2.3

