mirror of
https://github.com/knightcrawler-stremio/knightcrawler.git
synced 2024-12-20 03:29:51 +00:00
[scraper] add rutor scraper
This commit is contained in:
@@ -95,9 +95,12 @@ async function torrentFiles(torrent, timeout) {
|
||||
}
|
||||
|
||||
function getFilesFromObject(torrent) {
|
||||
if (torrent.files && torrent.files.length) {
|
||||
if (Array.isArray(torrent.files)) {
|
||||
return Promise.resolve(torrent.files);
|
||||
}
|
||||
if (typeof torrent.files === 'function') {
|
||||
return torrent.files();
|
||||
}
|
||||
return Promise.reject("No files in the object");
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user