mirror of
https://git.nadeko.net/Fijxu/invidious.git
synced 2025-12-16 09:58:50 +00:00
SigHelper: Make signature server optional and configurable
This commit is contained in:
@@ -2,8 +2,6 @@
|
||||
# This file contains youtube API wrappers
|
||||
#
|
||||
|
||||
private STS_FETCHER = IV::DecryptFunction.new
|
||||
|
||||
module YoutubeAPI
|
||||
extend self
|
||||
|
||||
@@ -462,7 +460,7 @@ module YoutubeAPI
|
||||
} of String => String | Int64
|
||||
|
||||
if {"WEB", "TVHTML5"}.any? { |s| client_config.name.starts_with? s }
|
||||
if sts = STS_FETCHER.get_sts
|
||||
if sts = DECRYPT_FUNCTION.try &.get_sts
|
||||
playback_ctx["signatureTimestamp"] = sts.to_i64
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user