Update dbMigration mappings

This commit is contained in:
advplyr 2023-07-14 14:04:28 -05:00
parent e40e0bfa25
commit 9b7aacf3ea
2 changed files with 4 additions and 4 deletions

View File

@ -107,7 +107,7 @@ export default {
this.$toast.error('Invalid number of backups to keep')
return
}
var updatePayload = {
const updatePayload = {
backupSchedule: this.enableBackups ? this.cronExpression : false,
backupsToKeep: Number(this.backupsToKeep),
maxBackupSize: Number(this.maxBackupSize)

View File

@ -151,8 +151,8 @@ function migratePodcast(oldLibraryItem, LibraryItem) {
autoDownloadEpisodes: !!oldPodcast.autoDownloadEpisodes,
autoDownloadSchedule: oldPodcast.autoDownloadSchedule,
lastEpisodeCheck: oldPodcast.lastEpisodeCheck,
maxEpisodesToKeep: oldPodcast.maxEpisodesToKeep,
maxNewEpisodesToDownload: oldPodcast.maxNewEpisodesToDownload,
maxEpisodesToKeep: oldPodcast.maxEpisodesToKeep || 0,
maxNewEpisodesToDownload: oldPodcast.maxNewEpisodesToDownload || 3,
lastCoverSearchQuery: oldPodcast.lastCoverSearchQuery,
lastCoverSearch: oldPodcast.lastCoverSearch,
createdAt: LibraryItem.createdAt,
@ -189,7 +189,7 @@ function migratePodcast(oldLibraryItem, LibraryItem) {
updatedAt: oldEpisode.updatedAt,
podcastId: Podcast.id,
audioFile: oldEpisode.audioFile,
chapters: oldEpisode.chapters
chapters: oldEpisode.chapters || []
}
newRecords.podcastEpisode.push(PodcastEpisode)
oldDbIdMap.podcastEpisodes[oldEpisode.id] = PodcastEpisode.id