mirror of
https://gitea.invidious.io/iv-org/invidious-copy-2023-06-08.git
synced 2024-08-15 00:53:38 +00:00
Add fix for dash sequences
This commit is contained in:
parent
d2bbf9d33c
commit
0e1b5d7cdd
1 changed files with 2 additions and 1 deletions
|
@ -258,6 +258,7 @@ class Video
|
||||||
|
|
||||||
def adaptive_fmts(decrypt_function)
|
def adaptive_fmts(decrypt_function)
|
||||||
adaptive_fmts = [] of HTTP::Params
|
adaptive_fmts = [] of HTTP::Params
|
||||||
|
|
||||||
if self.info.has_key?("adaptive_fmts")
|
if self.info.has_key?("adaptive_fmts")
|
||||||
self.info["adaptive_fmts"].split(",") do |string|
|
self.info["adaptive_fmts"].split(",") do |string|
|
||||||
adaptive_fmts << HTTP::Params.parse(string)
|
adaptive_fmts << HTTP::Params.parse(string)
|
||||||
|
@ -285,7 +286,7 @@ class Video
|
||||||
init = segment_list.xpath_node(%q(.//initialization))
|
init = segment_list.xpath_node(%q(.//initialization))
|
||||||
|
|
||||||
# TODO: Replace with sane defaults when byteranges are absent
|
# TODO: Replace with sane defaults when byteranges are absent
|
||||||
if init
|
if init && !init["sourceurl"].starts_with? "sq"
|
||||||
init = init["sourceurl"].lchop("range/")
|
init = init["sourceurl"].lchop("range/")
|
||||||
|
|
||||||
index = segment_list.xpath_node(%q(.//segmenturl)).not_nil!["media"]
|
index = segment_list.xpath_node(%q(.//segmenturl)).not_nil!["media"]
|
||||||
|
|
Loading…
Reference in a new issue