From cd0fa3e2232dcb522673143f113fc382fb2ff0a3 Mon Sep 17 00:00:00 2001 From: Fallenbagel <98979876+Fallenbagel@users.noreply.github.com> Date: Wed, 17 Apr 2024 16:07:02 +0500 Subject: [PATCH] Revert "fix: disable seasonfolder option in sonarr for jellyfin/Emby users" (#718) This reverts commit 8ec8f2ac5730aad3b12dcd8ed95bb553b46b399c. Disabling seasonfolder is no longer needed as we now allow virtualFolders from jellyfin api. --- src/components/Settings/SonarrModal/index.tsx | 24 +++---------------- 1 file changed, 3 insertions(+), 21 deletions(-) diff --git a/src/components/Settings/SonarrModal/index.tsx b/src/components/Settings/SonarrModal/index.tsx index 5267ef4e3..729a40a7b 100644 --- a/src/components/Settings/SonarrModal/index.tsx +++ b/src/components/Settings/SonarrModal/index.tsx @@ -1,10 +1,8 @@ import Modal from '@app/components/Common/Modal'; import SensitiveInput from '@app/components/Common/SensitiveInput'; -import useSettings from '@app/hooks/useSettings'; import globalMessages from '@app/i18n/globalMessages'; import { Transition } from '@headlessui/react'; -import { MediaServerType } from '@server/constants/server'; -import { type SonarrSettings } from '@server/lib/settings'; +import type { SonarrSettings } from '@server/lib/settings'; import axios from 'axios'; import { Field, Formik } from 'formik'; import { useCallback, useEffect, useRef, useState } from 'react'; @@ -111,7 +109,6 @@ const SonarrModal = ({ onClose, sonarr, onSave }: SonarrModalProps) => { const { addToast } = useToasts(); const [isValidated, setIsValidated] = useState(sonarr ? true : false); const [isTesting, setIsTesting] = useState(false); - const settings = useSettings(); const [testResponse, setTestResponse] = useState({ profiles: [], rootFolders: [], @@ -258,9 +255,7 @@ const SonarrModal = ({ onClose, sonarr, onSave }: SonarrModalProps) => { animeTags: sonarr?.animeTags ?? [], isDefault: sonarr?.isDefault ?? false, is4k: sonarr?.is4k ?? false, - enableSeasonFolders: - sonarr?.enableSeasonFolders ?? - settings.currentSettings.mediaServerType !== MediaServerType.PLEX, + enableSeasonFolders: sonarr?.enableSeasonFolders ?? false, externalUrl: sonarr?.externalUrl, syncEnabled: sonarr?.syncEnabled ?? false, enableSearch: !sonarr?.preventSearch, @@ -966,24 +961,11 @@ const SonarrModal = ({ onClose, sonarr, onSave }: SonarrModalProps) => { > {intl.formatMessage(messages.seasonfolders)} -
+