ActivityPub-federated video streaming platform using P2P directly in your web browser
Fix check unicast for imports
Chocobozzz129d0d8c9ab3
diff --git a/server/core/helpers/youtube-dl/youtube-dl-wrapper.ts b/server/core/helpers/youtube-dl/youtube-dl-wrapper.tsindex 5ec61f023a..2898dbaf65 100644--- a/server/core/helpers/youtube-dl/youtube-dl-wrapper.ts+++ b/server/core/helpers/youtube-dl/youtube-dl-wrapper.ts@@ -264,7 +264,9 @@ export class YoutubeDLWrapper {}private async checkUnicastOrThrow (userLanguage: string) {- if (!await isResolvingToUnicastOnly(this.url)) {+ const host = new URL(this.url).hostname++ if (!await isResolvingToUnicastOnly(host)) {throw new YoutubeDlImportError({message: t(`URL {targetUrl} is not a unicast URL.`, userLanguage, { targetUrl: this.url }),code: YoutubeDlImportErrorCode.NOT_ONLY_UNICAST_URL