From 45b4adcf64b44a74bcf4ed936385fdf790195a06 Mon Sep 17 00:00:00 2001 From: Mirco Wittrien Date: Sun, 9 Apr 2023 11:47:02 +0200 Subject: [PATCH] Update 0BDFDB.plugin.js --- Library/0BDFDB.plugin.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Library/0BDFDB.plugin.js b/Library/0BDFDB.plugin.js index 4253a402d0..a9ae44bc44 100644 --- a/Library/0BDFDB.plugin.js +++ b/Library/0BDFDB.plugin.js @@ -2433,7 +2433,7 @@ module.exports = (_ => { if (!n || !n[1]) return; let funcString = typeof n[1] == "function" ? n[1].toString() : (_ => {try {return JSON.stringify(n[1])}catch(err){return n[1].toString()}})(); let renderFuncString = typeof n[1].render == "function" && n[1].render.toString() || ""; - return [dataStorage[item].funcStrings].flat(10).filter(s => s && typeof s == "string").every(string => funcString.indexOf(string) > -1 || renderFuncString.indexOf(string) > -1); + return [dataStorage[item].funcStrings].flat(10).filter(s => s && typeof s == "string").every(string => funcString && funcString.indexOf(string) > -1 || renderFuncString && renderFuncString.indexOf(string) > -1); }) || [])[1]; if (dataStorage[item].map) { dataStorage[item]._originalModule = moduleStorage[item]; @@ -2447,7 +2447,7 @@ module.exports = (_ => { if (!n || !n[1]) return; let funcString = typeof n[1] == "function" ? n[1].toString() : (_ => {try {return JSON.stringify(n[1])}catch(err){return n[1].toString()}})(); let renderFuncString = typeof n[1].render == "function" && n[1].render.toString() || ""; - return [dataStorage[item].map[item2]].flat(10).filter(s => s && typeof s == "string").every(string => funcString.indexOf(string) > -1 || renderFuncString.indexOf(string) > -1); + return [dataStorage[item].map[item2]].flat(10).filter(s => s && typeof s == "string").every(string => funcString && funcString.indexOf(string) > -1 || renderFuncString && renderFuncString.indexOf(string) > -1); }); if (foundFunc) { dataStorage[item]._mappedItems[item2] = foundFunc[0];