mirror of
https://gitea.invidious.io/iv-org/invidious-copy-2022-04-11.git
synced 2024-08-15 00:43:26 +00:00
Change status_code to that of response for videoplayback
This commit is contained in:
parent
2aca7f7c19
commit
9898b2900f
1 changed files with 1 additions and 5 deletions
|
@ -819,7 +819,7 @@ get "/videoplayback" do |env|
|
|||
url = URI.parse(response.headers["Location"])
|
||||
env.redirect url.full_path
|
||||
else
|
||||
env.response.status_code = 206
|
||||
env.response.status_code = response.status_code
|
||||
|
||||
response.headers.each do |key, value|
|
||||
env.response.headers[key] = value
|
||||
|
@ -830,10 +830,6 @@ get "/videoplayback" do |env|
|
|||
loop do
|
||||
count = response.body_io.read(chunk)
|
||||
|
||||
if count == 0
|
||||
break
|
||||
end
|
||||
|
||||
begin
|
||||
env.response.write(chunk)
|
||||
env.response.flush
|
||||
|
|
Loading…
Reference in a new issue