From 25739a11622c8e662ef0e592d55133f452c586cd Mon Sep 17 00:00:00 2001
From: MerlinScheurer
Date: Wed, 1 Jan 2025 13:02:29 +0100
Subject: [PATCH] Fix react error about input switching from uncontrolled to
controlled
---
frontend/src/pages/SettingsScheduling.tsx | 23 +++++++++++------------
1 file changed, 11 insertions(+), 12 deletions(-)
diff --git a/frontend/src/pages/SettingsScheduling.tsx b/frontend/src/pages/SettingsScheduling.tsx
index a73728e7..99a8d230 100644
--- a/frontend/src/pages/SettingsScheduling.tsx
+++ b/frontend/src/pages/SettingsScheduling.tsx
@@ -23,11 +23,11 @@ const SettingsScheduling = () => {
const [updateSubscribed, setUpdateSubscribed] = useState();
const [downloadPending, setDownloadPending] = useState();
const [checkReindex, setCheckReindex] = useState();
- const [checkReindexDays, setCheckReindexDays] = useState(undefined);
+ const [checkReindexDays, setCheckReindexDays] = useState();
const [thumbnailCheck, setThumbnailCheck] = useState();
const [zipBackup, setZipBackup] = useState();
- const [zipBackupDays, setZipBackupDays] = useState(undefined);
- const [notificationUrl, setNotificationUrl] = useState(undefined);
+ const [zipBackupDays, setZipBackupDays] = useState();
+ const [notificationUrl, setNotificationUrl] = useState();
const [notificationTask, setNotificationTask] = useState('');
useEffect(() => {
@@ -136,7 +136,7 @@ const SettingsScheduling = () => {
{
setUpdateSubscribed(e.currentTarget.value);
}}
@@ -182,7 +182,7 @@ const SettingsScheduling = () => {
{
setDownloadPending(e.currentTarget.value);
}}
@@ -229,7 +229,7 @@ const SettingsScheduling = () => {
{
setCheckReindex(e.currentTarget.value);
}}
@@ -256,7 +256,7 @@ const SettingsScheduling = () => {
{
setCheckReindexDays(Number(e.currentTarget.value));
}}
@@ -305,7 +305,7 @@ const SettingsScheduling = () => {
{
setThumbnailCheck(e.currentTarget.value);
}}
@@ -358,7 +358,7 @@ const SettingsScheduling = () => {
{
setZipBackup(e.currentTarget.value);
}}
@@ -385,7 +385,7 @@ const SettingsScheduling = () => {
{
setZipBackupDays(Number(e.currentTarget.value));
}}
@@ -452,7 +452,6 @@ const SettingsScheduling = () => {