From dad8f9a0ce576ce3e938fbaa578d12179ca63553 Mon Sep 17 00:00:00 2001 From: Samantaz Fox Date: Tue, 16 Nov 2021 20:39:26 +0100 Subject: [PATCH] Fix typo Should be checking the returned headers, not the sent ones. --- src/invidious/yt_backend/youtube_api.cr | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/invidious/yt_backend/youtube_api.cr b/src/invidious/yt_backend/youtube_api.cr index 0403cb56..4973e4de 100644 --- a/src/invidious/yt_backend/youtube_api.cr +++ b/src/invidious/yt_backend/youtube_api.cr @@ -431,7 +431,7 @@ module YoutubeAPI # - https://github.com/iv-org/invidious/issues/2612 # - https://github.com/crystal-lang/crystal/issues/11354 # - case headers["Content-Encoding"]? + case response.headers["Content-Encoding"]? when "gzip" body = Compress::Gzip::Reader.new(response.body_io, sync_close: true) when "deflate"