mirror of
https://github.com/knightcrawler-stremio/knightcrawler.git
synced 2024-12-20 03:29:51 +00:00
[addon] show rar error static response for alldebrid
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
const RealDebridClient = require('real-debrid-api');
|
||||
const { encode } = require('magnet-uri');
|
||||
const isVideo = require('../lib/video');
|
||||
const { isVideo, isArchive } = require('../lib/extension');
|
||||
const delay = require('./delay');
|
||||
const StaticResponse = require('./static');
|
||||
const { getRandomProxy, getRandomUserAgent } = require('../lib/request_helper');
|
||||
@@ -146,7 +146,7 @@ async function _unrestrictLink(RD, torrent, fileIndex) {
|
||||
}
|
||||
|
||||
const unrestrictedLink = await RD.unrestrict.link(fileLink).then(response => response.download);
|
||||
if (!isVideo(unrestrictedLink)) {
|
||||
if (isArchive(unrestrictedLink)) {
|
||||
return StaticResponse.FAILED_RAR;
|
||||
}
|
||||
// const transcodedLink = await RD.streaming.transcode(unrestrictedLink.id);
|
||||
|
||||
Reference in New Issue
Block a user