From c78941a39a20ee92694174a003e6478f9f319fa4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C4=81nis=20L?= Date: Mon, 20 Jul 2026 17:45:06 +0300 Subject: [PATCH] fix le shit --- manifest.json | 4 ++-- providers/miruro.js | 3 ++- src/miruro/extractor.js | 7 ++++++- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/manifest.json b/manifest.json index 0bcf6fe..ab43a89 100644 --- a/manifest.json +++ b/manifest.json @@ -1,12 +1,12 @@ { "name": "Nuvio Providers", - "version": "1.0.8", + "version": "1.0.9", "scrapers": [ { "id": "miruro", "name": "Miruro", "description": "Anime streams from Miruro with subbed and dubbed sources.", - "version": "1.0.2", + "version": "1.0.3", "author": "Jānis L", "supportedTypes": [ "movie", diff --git a/providers/miruro.js b/providers/miruro.js index db73e18..0439c4c 100644 --- a/providers/miruro.js +++ b/providers/miruro.js @@ -579,7 +579,8 @@ function recordMatchesIdentifier(record, identifier, mediaType) { } function getAniListIds(records, identifier, mediaType) { const ids = []; - for (const record of Array.isArray(records) ? records : []) { + const normalizedRecords = Array.isArray(records) ? records : records && typeof records === "object" ? [records] : []; + for (const record of normalizedRecords) { if (!recordMatchesIdentifier(record, identifier, mediaType)) { continue; } diff --git a/src/miruro/extractor.js b/src/miruro/extractor.js index d68d75d..4ba6596 100644 --- a/src/miruro/extractor.js +++ b/src/miruro/extractor.js @@ -59,8 +59,13 @@ function recordMatchesIdentifier(record, identifier, mediaType) { function getAniListIds(records, identifier, mediaType) { const ids = []; + const normalizedRecords = Array.isArray(records) + ? records + : records && typeof records === 'object' + ? [records] + : []; - for (const record of Array.isArray(records) ? records : []) { + for (const record of normalizedRecords) { if (!recordMatchesIdentifier(record, identifier, mediaType)) { continue; }