From d6a9c83e0883916c29b257f4b4a9de345e8feb59 Mon Sep 17 00:00:00 2001 From: src48597962 <48597962@qq.com> Date: Fri, 18 Oct 2024 08:29:04 +0800 Subject: [PATCH] =?UTF-8?q?=E6=9B=B4=E6=96=B0=20'SrcJyPublic.js'?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- SrcJyPublic.js | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/SrcJyPublic.js b/SrcJyPublic.js index 2f37eb4a..b46f65fc 100644 --- a/SrcJyPublic.js +++ b/SrcJyPublic.js @@ -824,8 +824,9 @@ function shareResource() { url: resources.length>=3?"toast://分享资源码不能超过3个":$().lazyRule(() => { try{ let pastecreate = JSON.parse(request('https://pasteme.tyrantg.com/api/create', { - body: 'content=juying&auto_password=1', - method: 'POST' + "content-type": "application/json;charset=UTF-8", + "body": "content=juying&auto_password=1", + "method": "POST" })); if(pastecreate.result_code=="SUCCESS"){ let data = pastecreate.data; @@ -875,8 +876,9 @@ function shareResource() { it.path = it.path + (it.path.includes('@')?'':'@juying'); showLoading("执行中,请稍后"); let pastecreate = JSON.parse(request('https://pasteme.tyrantg.com/api/update', { - body: 'content=juying&path='+it.path+'&auth_code='+it.token, - method: 'POST' + "content-type": "application/json;charset=UTF-8", + "body": "content=juying&path="+it.path+"&auth_code="+it.token, + "method": "POST" })); if(pastecreate.result_code=="SUCCESS"){ let resources = Juconfig['shareResource'] || []; @@ -984,8 +986,9 @@ function shareResource() { let textcontent = globalMap0.getVar('Jy_gmParams').zip(JSON.stringify(text)); try{ let pasteupdate = JSON.parse(request('https://pasteme.tyrantg.com/api/update', { - body: 'content='+textcontent+'&path='+it.path+'&auth_code='+it.token, - method: 'POST' + "content-type": "application/json;charset=UTF-8", + "body": "content="+textcontent+"&path="+it.path+"&auth_code="+it.token, + "method": "POST" })); if(pasteupdate.result_code=="SUCCESS"){ let resources = Juconfig['shareResource'] || [];