openzca 0.1.19 → 0.1.20
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 +8 -2
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -848,8 +848,14 @@ async function stopUploadListenerSafely(api, command, waitClosedMs = 1500) {
|
|
|
848
848
|
api.listener.on("closed", onClosed);
|
|
849
849
|
timeoutId = setTimeout(finish, waitClosedMs);
|
|
850
850
|
try {
|
|
851
|
-
api.listener.
|
|
852
|
-
|
|
851
|
+
const internalWs = api.listener.ws;
|
|
852
|
+
if (internalWs && typeof internalWs.close === "function") {
|
|
853
|
+
internalWs.close(1e3);
|
|
854
|
+
writeDebugLine("msg.upload.listener.stop.ws_close", void 0, command);
|
|
855
|
+
} else {
|
|
856
|
+
api.listener.stop();
|
|
857
|
+
writeDebugLine("msg.upload.listener.stop", void 0, command);
|
|
858
|
+
}
|
|
853
859
|
} catch {
|
|
854
860
|
finish();
|
|
855
861
|
}
|