chore:2.0.5

This commit is contained in:
曾文豪
2025-01-03 22:06:16 +08:00
parent 135f482729
commit b3336a5da0
2 changed files with 3 additions and 3 deletions

View File

@@ -1,6 +1,6 @@
{ {
"name": "@tiesheng/npm-tool", "name": "@tiesheng/npm-tool",
"version": "2.0.4", "version": "2.0.5",
"description": "npm tool package", "description": "npm tool package",
"main": "index.js", "main": "index.js",
"scripts": { "scripts": {

View File

@@ -73,10 +73,10 @@ const dealParamsBody = (options) => {
extraParams = GlobalConfig.getConfig().httpParams(); extraParams = GlobalConfig.getConfig().httpParams();
} }
if (options.method === "GET") { if (options.method === "GET") {
options.params = {...options.params, ...extraParams}; options.params = {...extraParams, ...options.params};
} else { } else {
if (options.requestType !== 'form') { if (options.requestType !== 'form') {
options.data = {...options.data, ...extraParams}; options.data = {...extraParams, ...options.data,};
options.data = { options.data = {
'encryptData': crypto.encrypt(JSON.stringify(options.data)) 'encryptData': crypto.encrypt(JSON.stringify(options.data))
} }