summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorOmar Roth <omarroth@protonmail.com>2020-05-08 08:59:09 -0500
committerOmar Roth <omarroth@protonmail.com>2020-05-08 08:59:09 -0500
commit75450dcdbcaf5f175147eb4f1e9db435804b593f (patch)
treee279770a9711b8c2acac5530080c0db98df15f0b /src
parentbd2c7e3bb900e6a9134c4fad08497b399195eb85 (diff)
downloadinvidious-75450dcdbcaf5f175147eb4f1e9db435804b593f.tar.gz
invidious-75450dcdbcaf5f175147eb4f1e9db435804b593f.tar.bz2
invidious-75450dcdbcaf5f175147eb4f1e9db435804b593f.zip
Update signature param
Diffstat (limited to 'src')
-rw-r--r--src/invidious/videos.cr8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/invidious/videos.cr b/src/invidious/videos.cr
index f9d3dc28..7e815ca1 100644
--- a/src/invidious/videos.cr
+++ b/src/invidious/videos.cr
@@ -562,8 +562,8 @@ struct Video
if fmt_stream["url"]?
fmt["url"] = fmt_stream["url"].as_s
end
- if fmt_stream["cipher"]?
- HTTP::Params.parse(fmt_stream["cipher"].as_s).each do |key, value|
+ if cipher = fmt_stream["cipher"]? || fmt_stream["signatureCipher"]?
+ HTTP::Params.parse(cipher.as_s).each do |key, value|
fmt[key] = value
end
end
@@ -638,8 +638,8 @@ struct Video
if adaptive_fmt["url"]?
fmt["url"] = adaptive_fmt["url"].as_s
end
- if adaptive_fmt["cipher"]?
- HTTP::Params.parse(adaptive_fmt["cipher"].as_s).each do |key, value|
+ if cipher = adaptive_fmt["cipher"]? || adaptive_fmt["signatureCipher"]?
+ HTTP::Params.parse(cipher.as_s).each do |key, value|
fmt[key] = value
end
end