mirror of
https://github.com/zoriya/flood.git
synced 2026-05-28 17:33:15 +00:00
Fix torrent filter
This commit is contained in:
@@ -1,10 +1,10 @@
|
||||
export function filterTorrents(torrents, filterBy) {
|
||||
export function filterTorrents(torrentList, filterBy) {
|
||||
if (filterBy !== 'all') {
|
||||
torrents = torrentList.filter(torrent => {
|
||||
torrentList = torrentList.filter(torrent => {
|
||||
if (torrent.status.indexOf('is-' + filterBy) > -1) {
|
||||
return torrent;
|
||||
}
|
||||
});
|
||||
}
|
||||
return torrents;
|
||||
return torrentList;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user