diff --git a/test.go b/test.go index fcc1857..2258187 100644 --- a/test.go +++ b/test.go @@ -80,5 +80,6 @@ func (t TestSettings) testYoutubeSong() { skip(dummyUser, false, false) } + os.Exit(0) //dummyClient.Disconnect() } diff --git a/youtube_dl.go b/youtube_dl.go index 83a120c..cb1ce8d 100644 --- a/youtube_dl.go +++ b/youtube_dl.go @@ -39,7 +39,7 @@ func (dl *YouTubeDLSong) Download() error { // Checks to see if song is already downloaded if _, err := os.Stat(fmt.Sprintf("%s/.mumbledj/songs/%s", dj.homeDir, dl.Filename())); os.IsNotExist(err) { - cmd := exec.Command("youtube-dl", "--output", fmt.Sprintf("%s/.mumbledj/songs/%s", dj.homeDir, dl.Filename()), "--format m4a", "--prefer-ffmpeg", dl.url) + cmd := exec.Command("youtube-dl", "--output", fmt.Sprintf("%s/.mumbledj/songs/%s", dj.homeDir, dl.Filename()), "--format m4a", "--prefer-ffmpeg", "--", dl.ID()) err = cmd.Run() if err == nil { if dj.conf.Cache.Enabled {