Skip to content

Commit

Permalink
chore(playlist): number downloaded songs in playlist
Browse files Browse the repository at this point in the history
  • Loading branch information
mbaraa committed Jun 30, 2024
1 parent 968f0cd commit c846443
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/services/playlists/playlists.go
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,7 @@ func (p *Service) Download(playlistPubId string, ownerId uint) (io.Reader, error
return nil, err
}
newShit, err := os.OpenFile(
fmt.Sprintf("%s/%s.mp3", config.Env().YouTube.MusicDir, song.Title),
fmt.Sprintf("%s/%d-%s.mp3", config.Env().YouTube.MusicDir, i+1, song.Title),
os.O_WRONLY|os.O_CREATE, 0644,
)
io.Copy(newShit, ogFile)
Expand Down

0 comments on commit c846443

Please sign in to comment.