mirror of
https://github.com/wukko/cobalt.git
synced 2025-05-01 06:44:24 +02:00
api/youtube: return an appropriate error if a video is locked behind DRM
This commit is contained in:
parent
d00d94f3dc
commit
2ebe2899be
@ -428,6 +428,10 @@ export default async function (o) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (video?.drm_families || audio?.drm_families) {
|
||||||
|
return { error: "youtube.drm" };
|
||||||
|
}
|
||||||
|
|
||||||
const fileMetadata = {
|
const fileMetadata = {
|
||||||
title: basicInfo.title.trim(),
|
title: basicInfo.title.trim(),
|
||||||
artist: basicInfo.author.replace("- Topic", "").trim()
|
artist: basicInfo.author.replace("- Topic", "").trim()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user