Update src/invidious/routes/watch.cr

Co-authored-by: Samantaz Fox <coding@samantaz.fr>
This commit is contained in:
syeopite 2023-11-14 20:35:28 +00:00 committed by syeopite
parent b34c79a6ea
commit 136bea11df
No known key found for this signature in database
GPG Key ID: A73C186DA3955A1A

View File

@ -52,11 +52,7 @@ module Invidious::Routes::Watch
env.params.query.delete_all("listen") env.params.query.delete_all("listen")
begin begin
if params.quality == "hls" video = get_video(id, region: params.region, force_hls: (params.quality == "hls"))
video = get_video(id, region: params.region, force_hls: true)
else
video = get_video(id, region: params.region)
end
rescue ex : NotFoundException rescue ex : NotFoundException
LOGGER.error("get_video not found: #{id} : #{ex.message}") LOGGER.error("get_video not found: #{id} : #{ex.message}")
return error_template(404, ex) return error_template(404, ex)