@hile/message-modem 1.0.5 → 1.0.6
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/index.d.ts +1 -0
- package/dist/index.js +10 -0
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
package/dist/index.js
CHANGED
|
@@ -10,6 +10,16 @@ export class MessageModem {
|
|
|
10
10
|
id = 0;
|
|
11
11
|
aborts = new Map();
|
|
12
12
|
stacks = new Map();
|
|
13
|
+
_dispose() {
|
|
14
|
+
for (const { reject } of this.stacks.values()) {
|
|
15
|
+
reject(new AbortException());
|
|
16
|
+
}
|
|
17
|
+
for (const reject of this.aborts.values()) {
|
|
18
|
+
reject(new AbortException());
|
|
19
|
+
}
|
|
20
|
+
this.aborts.clear();
|
|
21
|
+
this.stacks.clear();
|
|
22
|
+
}
|
|
13
23
|
/**
|
|
14
24
|
* 创建自增 ID
|
|
15
25
|
* 超过最大安全整数时重置为 0
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hile/message-modem",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.6",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -21,5 +21,5 @@
|
|
|
21
21
|
"fix-esm-import-path": "^1.10.3",
|
|
22
22
|
"vitest": "^4.0.18"
|
|
23
23
|
},
|
|
24
|
-
"gitHead": "
|
|
24
|
+
"gitHead": "fabc6e8b039b9ac6bf3267b825f7295d04111264"
|
|
25
25
|
}
|