From 4b359ddd61d3f16a8fc0e9da1ddad20f5d4b6b42 Mon Sep 17 00:00:00 2001 From: Gamers_indo1223 <76719536+gamersindo1223@users.noreply.github.com> Date: Mon, 8 Jul 2024 10:06:40 +0000 Subject: [PATCH] Use existing Force IPV4 Config --- goutubedl.go | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/goutubedl.go b/goutubedl.go index f3adb26..2c3fb7e 100644 --- a/goutubedl.go +++ b/goutubedl.go @@ -527,10 +527,7 @@ type DownloadOptions struct { Filter string // The index of the entry to download from the playlist that would be // passed to youtube-dl via --playlist-items. The index value starts at 1 - PlaylistIndex int - - // -4 Make all connections via IPv4 - UseIPV4 bool + PlaylistIndex int } func (result Result) DownloadWithOptions( @@ -613,7 +610,7 @@ func (result Result) DownloadWithOptions( cmd.Args = append(cmd.Args, "--load-info", jsonTempPath) } //Force IPV4 Usage - if options.UseIPV4 { + if result.Options.UseIPV4 { cmd.Args = append(cmd.Args, "-4") } // don't need to specify if direct as there is only one