From 2f15c920d435e148de25e15eb2276eacd8da245e Mon Sep 17 00:00:00 2001 From: Niko Storni Date: Fri, 25 Jun 2021 19:16:01 +0200 Subject: [PATCH] speed up playlist listing --- downloader/downloader.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/downloader/downloader.go b/downloader/downloader.go index 1a64e08..0d8dff0 100644 --- a/downloader/downloader.go +++ b/downloader/downloader.go @@ -29,7 +29,7 @@ import ( ) func GetPlaylistVideoIDs(channelName string, maxVideos int, stopChan stop.Chan, pool *ip_manager.IPPool) ([]string, error) { - args := []string{"--skip-download", "https://www.youtube.com/channel/" + channelName + "/videos", "--get-id", "--flat-playlist", "--cookies", "cookies.txt"} + args := []string{"--skip-download", "https://www.youtube.com/channel/" + channelName + "/videos", "--get-id", "--flat-playlist", "--cookies", "cookies.txt", "--playlist-end", fmt.Sprintf("%d", maxVideos)} ids, err := run(channelName, args, stopChan, pool) if err != nil { return nil, errors.Err(err)