matchActionDecider: always render tiktok m4a

This commit is contained in:
wukko 2024-05-22 02:38:32 +06:00
parent 2d06b5e970
commit fe0a2583da
No known key found for this signature in database
GPG Key ID: 3E30B3F26C7B4AA2

View File

@ -70,7 +70,7 @@ export default function(r, host, userFormat, isAudioOnly, lang, isAudioMuted, di
break; break;
case "tiktok": case "tiktok":
let audioStreamType = "render"; let audioStreamType = "render";
if (audioFormat === "mp3" || audioFormat === "best") { if (r.bestAudio === "mp3" && (audioFormat === "mp3" || audioFormat === "best")) {
audioFormat = "mp3"; audioFormat = "mp3";
audioStreamType = "bridge" audioStreamType = "bridge"
} }
@ -153,11 +153,12 @@ export default function(r, host, userFormat, isAudioOnly, lang, isAudioMuted, di
const isTumblrAudio = host === "tumblr" && !r.filename; const isTumblrAudio = host === "tumblr" && !r.filename;
const isSoundCloud = host === "soundcloud"; const isSoundCloud = host === "soundcloud";
const isTiktok = host === "tiktok";
if (isBestAudioDefined || isBestHostAudio) { if (isBestAudioDefined || isBestHostAudio) {
audioFormat = serviceBestAudio; audioFormat = serviceBestAudio;
processType = "bridge"; processType = "bridge";
if (isSoundCloud) { if (isSoundCloud || (isTiktok && audioFormat === "m4a")) {
processType = "render" processType = "render"
copy = true copy = true
} }