probably the biggest update in history of cobalt
This commit is contained in:
wukko
2022-08-12 19:36:19 +06:00
parent 2fae43d890
commit 54c14232d5
42 changed files with 896 additions and 385 deletions

View File

@@ -7,7 +7,7 @@ import { errorUnsupported } from "./sub/errors.js";
import loc from "../localization/manager.js";
import match from "./match.js";
export async function getJSON(originalURL, ip, lang, format, quality) {
export async function getJSON(originalURL, ip, lang, format, quality, audioFormat, isAudioOnly) {
try {
let url = decodeURI(originalURL);
if (!url.includes('http://')) {
@@ -28,7 +28,7 @@ export async function getJSON(originalURL, ip, lang, format, quality) {
if (patternMatch) break;
}
if (patternMatch) {
return await match(host, patternMatch, url, ip, lang, format, quality);
return await match(host, patternMatch, url, ip, lang, format, quality, audioFormat, isAudioOnly);
} return apiJSON(0, { t: errorUnsupported(lang) } )
} return apiJSON(0, { t: errorUnsupported(lang) } )
} else {