mirror of
https://gitea.invidious.io/iv-org/invidious-copy-2022-04-11.git
synced 2024-08-15 00:43:26 +00:00
Chop leading slash from local URLs
This commit is contained in:
parent
a3a826e52c
commit
0b363ff471
1 changed files with 2 additions and 2 deletions
|
@ -2566,7 +2566,7 @@ get "/api/manifest/dash/id/:id" do |env|
|
|||
url = url.rchop("</BaseURL>")
|
||||
|
||||
if local
|
||||
url = URI.parse(url).full_path
|
||||
url = URI.parse(url).full_path.lchop("/")
|
||||
end
|
||||
|
||||
"<BaseURL>#{url}</BaseURL>"
|
||||
|
@ -2579,7 +2579,7 @@ get "/api/manifest/dash/id/:id" do |env|
|
|||
|
||||
if local
|
||||
adaptive_fmts.each do |fmt|
|
||||
fmt["url"] = URI.parse(fmt["url"]).full_path
|
||||
fmt["url"] = URI.parse(fmt["url"]).full_path.lchop("/")
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue