From cad8f1f716379c044f2eb791086d45cbd80527aa Mon Sep 17 00:00:00 2001 From: src48597962 <48597962@qq.com> Date: Fri, 31 Mar 2023 09:20:28 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=20'SrcJuman.js'?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- SrcJuman.js | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/SrcJuman.js b/SrcJuman.js index f037ea7c..f0829564 100644 --- a/SrcJuman.js +++ b/SrcJuman.js @@ -65,12 +65,23 @@ function yiji() { }else{ let source = sourcedata[0].parse; if($.type(source)=="string" && /^http/.test(source)){ - var colorsz = ['#519D9E', '#285943', '#098AC1']; requireCache(source, 48); MY_URL = parse['链接']; - let html = request(MY_URL); - eval("let 主页 = " + parse['主页']) - d = d.concat(主页()); + let 主页数据 = []; + try{ + eval("let 主页 = " + parse['主页']) + 主页数据 = 主页(); + }catch(e){ + log(e.message); + } + if(主页数据.length==0){ + 主页数据.push({ + title: "主页源的主页数据获取失败", + url: "hiker://empty", + col_type: "text_center_1", + }) + } + d = d.concat(主页数据); } }