fixed season folder toggle

This commit is contained in:
stratuma 2024-06-21 12:53:50 +02:00
parent 2a201156f7
commit 6bb8901f25
2 changed files with 3 additions and 3 deletions

View File

@ -277,7 +277,7 @@ ipcMain.handle('dialog:proxyActiveSet', async (events, status: boolean) => {
ipcMain.handle('dialog:getSeasonEnabledTemplate', async (events) => {
const savedStat = await settings.get('seasonFolderActive')
if (!savedStat) {
if (savedStat === undefined || savedStat === null) {
await settings.set('seasonFolderActive', true)
return true
}

View File

@ -23,6 +23,6 @@ contextBridge.exposeInMainWorld('myAPI', {
getEpisodeTemplate: () => ipcRenderer.invoke('dialog:getEpisodeTemplate'),
setSeasonTemplate: (name: string) => ipcRenderer.invoke('dialog:setSeasonTemplate', name),
getSeasonTemplate: () => ipcRenderer.invoke('dialog:getSeasonTemplate'),
setSeasonEnabled: (status: boolean) => ipcRenderer.invoke('dialog:setSeasonEnabledTemplate', status),
getSeasonEnabled: (status: boolean) => ipcRenderer.invoke('dialog:getSeasonEnabledTemplate', status)
setSeasonEnabled: (active: boolean) => ipcRenderer.invoke('dialog:setSeasonEnabledTemplate', active),
getSeasonEnabled: () => ipcRenderer.invoke('dialog:getSeasonEnabledTemplate')
})