Skip to content

Commit 38ab0b0

Browse files
committed
fix podcast mkdir for podcast episode
1 parent 7b21e82 commit 38ab0b0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

podcast/podcast.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -484,7 +484,7 @@ func (p *Podcasts) doPodcastDownload(podcast *db.Podcast, podcastEpisode *db.Pod
484484
if err := p.db.Save(&podcastEpisode).Error; err != nil {
485485
return fmt.Errorf("save podcast episode: %w", err)
486486
}
487-
if err := os.MkdirAll(filepath.Dir(podcastEpisode.Filename), os.ModePerm); err != nil {
487+
if err := os.MkdirAll(filepath.Dir(filepath.Join(podcast.RootDir, podcastEpisode.Filename)), os.ModePerm); err != nil {
488488
return fmt.Errorf("make podcast root dir: %w", err)
489489
}
490490
file, err := os.Create(filepath.Join(podcast.RootDir, podcastEpisode.Filename))

0 commit comments

Comments
 (0)