Skip to content

Commit fa82f1d

Browse files
committed
style: format code
1 parent b3d9469 commit fa82f1d

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ const isJSONstr = str => {
1313
return false
1414
}
1515
}
16-
export default function mpAdapter(config: AxiosRequestConfig, {
16+
export default function mpAdapter (config: AxiosRequestConfig, {
1717
transformRequestOption = requestOption => requestOption
1818
}: {
1919
transformRequestOption?: (requestOption: any) => any

src/utils/platForm.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ export function transformConfig (config: MpRequestConfig): any {
116116
if ([EnumPlatForm.支付宝, EnumPlatForm.钉钉].includes(platFormName)) {
117117
config.headers = config.header
118118
delete config.header
119-
if (EnumPlatForm.钉钉 === platFormName && config.method !== "GET" && config.headers?.['Content-Type'] === 'application/json' && Object.prototype.toString.call(config.data) === '[object Object]') {
119+
if (EnumPlatForm.钉钉 === platFormName && config.method !== 'GET' && config.headers?.['Content-Type'] === 'application/json' && Object.prototype.toString.call(config.data) === '[object Object]') {
120120
// Content-Type为application/json时,data参数只支持json字符串,需要手动调用JSON.stringify进行序列化
121121
config.data = JSON.stringify(config.data)
122122
}

0 commit comments

Comments
 (0)