prettier formating

This commit is contained in:
stratuma 2024-06-21 00:02:51 +02:00
parent 1468cbcb3c
commit 2a201156f7
2 changed files with 5 additions and 5 deletions

View File

@ -530,7 +530,7 @@ export async function downloadCrunchyrollPlaylist(
const chapterFolder = await createFolder()
var downloadDir: string = downloadPath;
var downloadDir: string = downloadPath
var isSeasonFolderActive = (await settings.get('seasonFolderActive')) as string
@ -540,14 +540,14 @@ export async function downloadCrunchyrollPlaylist(
if (!seasonFolderNaming) {
seasonFolderNaming = '{seriesName} Season {seasonNumber}'
}
seasonFolderNaming = seasonFolderNaming
.replace('{seriesName}', name.replace(/[/\\?%*:|"<>]/g, ''))
.replace('{seasonNumber}', season.toString())
.replace('{seasonNumberDD}', season.toString().padStart(2, '0'))
.replace('{quality}', quality.toString() + 'p')
downloadDir = await createFolderName(seasonFolderNaming, downloadPath)
downloadDir = await createFolderName(seasonFolderNaming, downloadPath)
}
await updatePlaylistByID(downloadID, undefined, undefined, downloadDir)

View File

@ -24,5 +24,5 @@ contextBridge.exposeInMainWorld('myAPI', {
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),
getSeasonEnabled: (status: boolean) => ipcRenderer.invoke('dialog:getSeasonEnabledTemplate', status)
})