mirror of
https://github.com/imputnet/cobalt.git
synced 2025-06-28 09:28:29 +00:00
api/match: ignore subtitleLang if it's "none"
This commit is contained in:
parent
2396462c5c
commit
eb249a3eed
@ -73,6 +73,9 @@ export default async function({ host, patternMatch, params, isSession, isApiKey
|
|||||||
youtubeHLS = false;
|
youtubeHLS = false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const subtitleLang =
|
||||||
|
params.subtitleLang !== "none" ? params.subtitleLang : undefined;
|
||||||
|
|
||||||
switch (host) {
|
switch (host) {
|
||||||
case "twitter":
|
case "twitter":
|
||||||
r = await twitter({
|
r = await twitter({
|
||||||
@ -114,7 +117,7 @@ export default async function({ host, patternMatch, params, isSession, isApiKey
|
|||||||
isAudioMuted,
|
isAudioMuted,
|
||||||
dubLang: params.youtubeDubLang,
|
dubLang: params.youtubeDubLang,
|
||||||
youtubeHLS,
|
youtubeHLS,
|
||||||
subtitleLang: params.subtitleLang,
|
subtitleLang,
|
||||||
}
|
}
|
||||||
|
|
||||||
if (url.hostname === "music.youtube.com" || isAudioOnly) {
|
if (url.hostname === "music.youtube.com" || isAudioOnly) {
|
||||||
|
Loading…
Reference in New Issue
Block a user