From 878f67b7ffd9e1cff0682e790d0a5609a0fff872 Mon Sep 17 00:00:00 2001 From: Kloon ImKloon Date: Wed, 30 Aug 2023 18:06:34 +0200 Subject: [PATCH] Small fixes for vue3 --- frontend/src/api/share.js | 6 +++++- frontend/src/views/Files.vue | 3 ++- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/frontend/src/api/share.js b/frontend/src/api/share.js index 1ac4473a..28d550ea 100644 --- a/frontend/src/api/share.js +++ b/frontend/src/api/share.js @@ -23,7 +23,11 @@ export async function create(url, password = "", expires = "", unit = "hours") { } let body = "{}"; if (password != "" || expires !== "" || unit !== "hours") { - body = JSON.stringify({ password: password, expires: expires, unit: unit }); + body = JSON.stringify({ + password: password, + expires: expires.toString(), // backend expects string not number + unit: unit, + }); } return fetchJSON(url, { method: "POST", diff --git a/frontend/src/views/Files.vue b/frontend/src/views/Files.vue index 19ea4d69..e519bbeb 100644 --- a/frontend/src/views/Files.vue +++ b/frontend/src/views/Files.vue @@ -20,6 +20,7 @@