Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 80f70ae

Browse files
author
lowking
committed
ToolKit update done
1 parent e5aa601 commit 80f70ae

File tree

1 file changed

+4
-11
lines changed

1 file changed

+4
-11
lines changed

util/ToolKit.js

+4-11
Original file line numberDiff line numberDiff line change
@@ -516,18 +516,11 @@ function ToolKit(scriptName, scriptId, options) {
516516
// this.setVal(this.costTotalMsKey, JSON.stringify(0))
517517
}
518518

519-
done(value) {
520-
let key = `body`
521-
if (this.isRequest()) {
522-
if (this.isQuanX()) key = `content`
523-
if (this.isSurge()) key = `body`
524-
} else {
525-
this.costTime()
519+
done(value = {}) {
520+
this.costTime()
521+
if (this.isSurge() || this.isQuanX() || this.isLoon()) {
522+
$done(value)
526523
}
527-
let obj = {}
528-
obj[key] = value
529-
if (this.isQuanX()) this.isRequest() ? $done(obj) : null
530-
if (this.isSurge()) this.isRequest() ? $done(obj) : $done()
531524
}
532525

533526
getRequestUrl() {

0 commit comments

Comments
 (0)