From e2eda70f8366bfd35f52c841e0e2ca5e5c21fa96 Mon Sep 17 00:00:00 2001 From: mediabot-pt <295750538+mediabot-pt@users.noreply.github.com> Date: Thu, 2 Jul 2026 00:09:39 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E6=94=B9=E7=94=A8doc.selectFirst/el.tex?= =?UTF-8?q?t()=E7=9B=B4=E6=8E=A5=E8=B0=83=E7=94=A8=EF=BC=8C=E4=B8=8D?= =?UTF-8?q?=E4=BE=9D=E8=B5=96mediabot=E7=9A=84ScriptUtils?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/main/resources/scripts/default-nexusphp.groovy | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/par-core/src/main/resources/scripts/default-nexusphp.groovy b/par-core/src/main/resources/scripts/default-nexusphp.groovy index d8ee356..a174972 100644 --- a/par-core/src/main/resources/scripts/default-nexusphp.groovy +++ b/par-core/src/main/resources/scripts/default-nexusphp.groovy @@ -15,9 +15,9 @@ Map parse(String content, String url) { private Map parseUserInfo(doc) { def fields = [:] - def el = utils.selectFirst(doc, '#info_block, td.bottom.clearfix, .userbar') + def el = doc.selectFirst('#info_block, td.bottom.clearfix, .userbar') if (el) { - def t = utils.text(el) + def t = el.text() def um = t =~ /上传[::]\s*([0-9.,]+)\s*(TB|GB|MB|KB|B)?/ def dm = t =~ /下载[::]\s*([0-9.,]+)\s*(TB|GB|MB|KB|B)?/ def rm = t =~ /分享率[::]\s*([\d.,]+)/ @@ -119,9 +119,9 @@ Map sync(PluginContext ctx) { def url = ctx.siteUrl.replaceAll('/+\$', '') + '/index.php' def body = http.get(url, ctx.auth) def doc = Jsoup.parse(body) - def el = utils.selectFirst(doc, '#info_block, td.bottom.clearfix, .userbar') + def el = doc.selectFirst('#info_block, td.bottom.clearfix, .userbar') if (!el) { ctx.incomplete = true; return [message: '未找到用户信息'] } - def t = utils.text(el) + def t = el.text() def result = [:] def um = t =~ /上传[::]\s*([0-9.,]+)\s*(TB|GB|MB|KB|B)?/ def dm = t =~ /下载[::]\s*([0-9.,]+)\s*(TB|GB|MB|KB|B)?/