aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorfenn-cs <fenn25.fn@gmail.com>2024-03-19 00:10:56 +0100
committerfenn-cs <fenn25.fn@gmail.com>2024-03-26 14:14:06 +0100
commitd2b0848a292ab03943627b930cb617feaf819ea2 (patch)
tree769f845b9c03a597824b28c3bff5d3e955c6f597 /apps
parent4b7b9c3d5d7f4b60b087174f21780332d17fb604 (diff)
downloadnextcloud-server-d2b0848a292ab03943627b930cb617feaf819ea2.tar.gz
nextcloud-server-d2b0848a292ab03943627b930cb617feaf819ea2.zip
fix(share): Send empty expireDate when not expireDate set
When creating a new share, if the user unchecks "Set expiry date" no `expireDate` is sent to the server. However, the server then assumes the default configured, hence better to send an empty value. Signed-off-by: fenn-cs <fenn25.fn@gmail.com>
Diffstat (limited to 'apps')
-rw-r--r--apps/files_sharing/src/views/SharingDetailsTab.vue6
1 files changed, 2 insertions, 4 deletions
diff --git a/apps/files_sharing/src/views/SharingDetailsTab.vue b/apps/files_sharing/src/views/SharingDetailsTab.vue
index 3667870de5a..fbe43a06c11 100644
--- a/apps/files_sharing/src/views/SharingDetailsTab.vue
+++ b/apps/files_sharing/src/views/SharingDetailsTab.vue
@@ -868,9 +868,7 @@ export default {
fileInfo: this.fileInfo,
}
- if (this.hasExpirationDate) {
- incomingShare.expireDate = this.share.expireDate
- }
+ incomingShare.expireDate = this.hasExpirationDate ? this.share.expireDate : ''
if (this.isPasswordProtected) {
incomingShare.password = this.share.password
@@ -912,9 +910,9 @@ export default {
shareWith: share.shareWith,
permissions: share.permissions,
attributes: JSON.stringify(fileInfo.shareAttributes),
+ expireDate: share.expireDate,
...(share.note ? { note: share.note } : {}),
...(share.password ? { password: share.password } : {}),
- ...(share.expireDate ? { expireDate: share.expireDate } : {}),
})
return resultingShare
} catch (error) {