From e17b4768016c5b77e293e61124840329bd04c597 Mon Sep 17 00:00:00 2001 From: Davide Marcoli <69892203+davidemarcoli@users.noreply.github.com> Date: Wed, 15 May 2024 13:00:02 +0200 Subject: [PATCH] Re-add filter step in the processing of the streams (#215) --- src/addon/src/addon.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/addon/src/addon.js b/src/addon/src/addon.js index 64838e6..aa9f27b 100644 --- a/src/addon/src/addon.js +++ b/src/addon/src/addon.js @@ -3,6 +3,7 @@ import { addonBuilder } from 'stremio-addon-sdk'; import { cacheWrapStream } from './lib/cache.js'; import { dummyManifest } from './lib/manifest.js'; import * as repository from './lib/repository.js'; +import applyFilters from "./lib/filter.js"; import applySorting from './lib/sort.js'; import { toStreamInfo, applyStaticInfo } from './lib/streamInfo.js'; import { Type } from './lib/types.js'; @@ -32,6 +33,7 @@ builder.defineStreamHandler((args) => { .then(records => records .sort((a, b) => b.torrent.seeders - a.torrent.seeders || b.torrent.uploadDate - a.torrent.uploadDate) .map(record => toStreamInfo(record))))) + .then(streams => applyFilters(streams, args.extra)) .then(streams => applySorting(streams, args.extra)) .then(streams => applyStaticInfo(streams)) .then(streams => applyMochs(streams, args.extra))