diff --git a/Readme.md b/Readme.md index 0261ef5..34f8c7b 100644 --- a/Readme.md +++ b/Readme.md @@ -14,7 +14,7 @@ -->
Current Version -2021.08.25
+Current Version -2021.09.20
A self-hosted podcast manager to download episodes as soon as they become live diff --git a/client/episodes.html b/client/episodes.html index 92f029c..ee7bca4 100644 --- a/client/episodes.html +++ b/client/episodes.html @@ -67,7 +67,7 @@ class="u-full-width" src="/podcastitems/{{.ID}}/image" alt="{{ .Title }}" - lazy="lazy" + loading="lazy" />
Current Version | -2021.08.25 | +2021.09.20 |
Website | diff --git a/service/fileService.go b/service/fileService.go index c9857de..4c9fc56 100644 --- a/service/fileService.go +++ b/service/fileService.go @@ -346,6 +346,10 @@ func createConfigFolderIfNotExists(folder string) string { return createFolder(folder, dataPath) } +func deletePodcastFolder(folder string) error { + return os.RemoveAll(createDataFolderIfNotExists(folder)) +} + func getFileName(link string, title string, defaultExtension string) string { fileUrl, err := url.Parse(link) checkError(err) diff --git a/service/podcastService.go b/service/podcastService.go index d87b3c0..8efa1fa 100644 --- a/service/podcastService.go +++ b/service/podcastService.go @@ -676,6 +676,12 @@ func DeletePodcast(id string, deleteFiles bool) error { db.DeletePodcastItemById(item.ID) } + + err = deletePodcastFolder(podcast.Title) + if err != nil { + return err + } + err = db.DeletePodcastById(id) if err != nil { return err