m3u8_native
Some checks failed
Build on push and PRs / build (push) Failing after 5s
Automatic version updates / version_update (push) Failing after 6s

This commit is contained in:
2025-02-07 16:31:17 +03:00
parent 646859b4c1
commit 1815e33339

View File

@ -185,10 +185,11 @@ type Subtitle struct {
}
type Caption struct {
Ext string `json:"ext"`
URL string `json:"url"`
Name string `json:"name"`
Bytes []byte `json:"-"`
Ext string `json:"ext"`
Protocol string `json:"protocol"`
URL string `json:"url"`
Name string `json:"name"`
Bytes []byte `json:"-"`
}
func (f Format) String() string {
@ -495,6 +496,12 @@ func infoFromURL(
if options.DownloadSubtitlesFormat != "" && caption.Ext != options.DownloadSubtitlesFormat {
continue
}
// filter out m3u8_native protocol
if caption.Protocol != "" {
continue
}
resp, respErr := get(caption.URL)
if respErr == nil {
buf, err := io.ReadAll(resp.Body)