From eb86b831704340ffa6387271a338b15d9101fa27 Mon Sep 17 00:00:00 2001 From: TheBeastLT Date: Fri, 24 Jun 2022 09:09:42 +0300 Subject: [PATCH] add insecure parse to docker cmd --- addon/Dockerfile | 2 +- addon/moch/realdebrid.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/addon/Dockerfile b/addon/Dockerfile index 1d4ece6..9aaf66a 100644 --- a/addon/Dockerfile +++ b/addon/Dockerfile @@ -9,4 +9,4 @@ COPY package*.json ./ RUN npm ci --only-production COPY . . -CMD [ "node", "index.js" ] \ No newline at end of file +CMD [ "node", "--insecure-http-parser", "index.js" ] \ No newline at end of file diff --git a/addon/moch/realdebrid.js b/addon/moch/realdebrid.js index d8b51c6..f2a8a81 100644 --- a/addon/moch/realdebrid.js +++ b/addon/moch/realdebrid.js @@ -35,8 +35,8 @@ async function _getInstantAvailable(hashes, apiKey, retries = 3, maxChunkSize = if (!missingHashes.length) { return cachedResults } - - const RD = new RealDebridClient(apiKey, getDefaultOptions()); + const options = await getDefaultOptions(); + const RD = new RealDebridClient(apiKey, options); const hashBatches = chunkArray(missingHashes, maxChunkSize) return Promise.all(hashBatches.map(batch => RD.torrents.instantAvailability(batch) .then(response => {