@codebolt/codeboltjs 1.1.62 → 1.1.63
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/modules/terminal.js +3 -3
- package/package.json +1 -1
- package/src/modules/terminal.ts +3 -3
package/modules/terminal.js
CHANGED
|
@@ -96,9 +96,9 @@ const cbterminal = {
|
|
|
96
96
|
websocket_1.default.getWebsocket.on('message', (data) => {
|
|
97
97
|
const response = JSON.parse(data);
|
|
98
98
|
console.log("Received message:", response);
|
|
99
|
-
if (response.type === "commandOutput" || response.type === "commandError" || response.type === "commandFinish")
|
|
100
|
-
|
|
101
|
-
|
|
99
|
+
if (response.type === "commandOutput" || response.type === "commandError" || response.type === "commandFinish") {
|
|
100
|
+
this.eventEmitter.emit(response.type, response);
|
|
101
|
+
}
|
|
102
102
|
});
|
|
103
103
|
// Return an object that includes the event emitter and the stopProcess method
|
|
104
104
|
return this.eventEmitter;
|
package/package.json
CHANGED
package/src/modules/terminal.ts
CHANGED
|
@@ -97,9 +97,9 @@ const cbterminal = {
|
|
|
97
97
|
cbws.getWebsocket.on('message', (data: string) => {
|
|
98
98
|
const response = JSON.parse(data);
|
|
99
99
|
console.log("Received message:", response);
|
|
100
|
-
if (response.type === "commandOutput" || response.type === "commandError" || response.type === "commandFinish")
|
|
101
|
-
|
|
102
|
-
|
|
100
|
+
if (response.type === "commandOutput" || response.type === "commandError" || response.type === "commandFinish") {
|
|
101
|
+
this.eventEmitter.emit(response.type, response);
|
|
102
|
+
}
|
|
103
103
|
});
|
|
104
104
|
|
|
105
105
|
// Return an object that includes the event emitter and the stopProcess method
|