@zimic/interceptor 1.1.1-canary.1 → 1.1.2-canary.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli.js +1 -1
- package/dist/cli.js.map +1 -1
- package/dist/cli.mjs +1 -1
- package/dist/cli.mjs.map +1 -1
- package/dist/http.js +27 -19
- package/dist/http.js.map +1 -1
- package/dist/http.mjs +27 -19
- package/dist/http.mjs.map +1 -1
- package/package.json +6 -6
- package/src/http/interceptor/HttpInterceptorClient.ts +3 -3
package/package.json
CHANGED
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"api",
|
|
15
15
|
"static"
|
|
16
16
|
],
|
|
17
|
-
"version": "1.1.
|
|
17
|
+
"version": "1.1.2-canary.0",
|
|
18
18
|
"homepage": "https://zimic.dev/docs/interceptor",
|
|
19
19
|
"repository": {
|
|
20
20
|
"type": "git",
|
|
@@ -87,13 +87,13 @@
|
|
|
87
87
|
"picocolors": "^1.1.1",
|
|
88
88
|
"ws": "8.18.3",
|
|
89
89
|
"yargs": "18.0.0",
|
|
90
|
-
"zod": "^4.1.
|
|
90
|
+
"zod": "^4.1.9"
|
|
91
91
|
},
|
|
92
92
|
"optionalDependencies": {
|
|
93
93
|
"bufferutil": "4.0.9"
|
|
94
94
|
},
|
|
95
95
|
"devDependencies": {
|
|
96
|
-
"@types/node": "^24.
|
|
96
|
+
"@types/node": "^24.5.2",
|
|
97
97
|
"@types/ws": "^8.18.1",
|
|
98
98
|
"@types/yargs": "^17.0.33",
|
|
99
99
|
"@vitest/browser": "^3.2.4",
|
|
@@ -105,13 +105,13 @@
|
|
|
105
105
|
"typescript": "^5.9.2",
|
|
106
106
|
"vitest": "^3.2.4",
|
|
107
107
|
"@zimic/eslint-config-node": "0.0.0",
|
|
108
|
-
"@zimic/
|
|
108
|
+
"@zimic/lint-staged-config": "0.0.0",
|
|
109
109
|
"@zimic/tsconfig": "0.0.0",
|
|
110
|
-
"@zimic/
|
|
110
|
+
"@zimic/utils": "0.0.0"
|
|
111
111
|
},
|
|
112
112
|
"peerDependencies": {
|
|
113
113
|
"typescript": ">=5.0.0",
|
|
114
|
-
"@zimic/http": "^1.1.0 || 1.1.1
|
|
114
|
+
"@zimic/http": "^1.1.0 || 1.1.1"
|
|
115
115
|
},
|
|
116
116
|
"peerDependenciesMeta": {
|
|
117
117
|
"typescript": {
|
|
@@ -342,15 +342,15 @@ class HttpInterceptorClient<
|
|
|
342
342
|
}
|
|
343
343
|
|
|
344
344
|
clear(options: { onCommitSuccess?: () => void; onCommitError?: () => void } = {}) {
|
|
345
|
-
const clearResults:
|
|
346
|
-
this.workerOrThrow.clearInterceptorHandlers(this),
|
|
345
|
+
const clearResults: Promise<AnyHttpRequestHandlerClient | void>[] = [
|
|
346
|
+
Promise.resolve(this.workerOrThrow.clearInterceptorHandlers(this)),
|
|
347
347
|
];
|
|
348
348
|
|
|
349
349
|
for (const method of HTTP_METHODS) {
|
|
350
350
|
const newClearResults = this.clearMethodHandlers(method);
|
|
351
351
|
|
|
352
352
|
for (const result of newClearResults) {
|
|
353
|
-
clearResults.push(result);
|
|
353
|
+
clearResults.push(Promise.resolve(result));
|
|
354
354
|
}
|
|
355
355
|
|
|
356
356
|
const handlersByPath = this.handlerClientsByMethod[method];
|