@wutiange/log-listener-plugin 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- package/package.json +1 -1
- package/src/index.ts +3 -3
- package/src/server.ts +1 -1
package/package.json
CHANGED
package/src/index.ts
CHANGED
@@ -43,15 +43,15 @@ class Logger {
|
|
43
43
|
}
|
44
44
|
|
45
45
|
log(...data: any[]) {
|
46
|
-
this._log('log', data)
|
46
|
+
this._log('log', ...data)
|
47
47
|
}
|
48
48
|
|
49
49
|
warn(...data: any[]) {
|
50
|
-
this._log('warn', data)
|
50
|
+
this._log('warn', ...data)
|
51
51
|
}
|
52
52
|
|
53
53
|
error(...data: any[]) {
|
54
|
-
this._log('error', data)
|
54
|
+
this._log('error', ...data)
|
55
55
|
}
|
56
56
|
|
57
57
|
async req(input: RequestInfo | URL, init?: RequestInit) {
|
package/src/server.ts
CHANGED
@@ -9,7 +9,7 @@ class Server {
|
|
9
9
|
const result = await fetch(`${this.baseUrl}:${this.port}/${path}`, {
|
10
10
|
method: 'POST',
|
11
11
|
headers: {
|
12
|
-
'Content-Type': 'application/json;charset
|
12
|
+
'Content-Type': 'application/json;charset=utf-8'
|
13
13
|
},
|
14
14
|
body: JSON.stringify(data)
|
15
15
|
})
|