verteilen-core 1.2.19 → 1.2.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/server/detail.js +15 -11
- package/package.json +1 -1
- package/src/server/detail.ts +13 -9
package/dist/server/detail.js
CHANGED
|
@@ -191,21 +191,25 @@ class ServerDetail {
|
|
|
191
191
|
};
|
|
192
192
|
shell_open = (socket, uuid) => {
|
|
193
193
|
this.websocket_manager.shell_open(uuid);
|
|
194
|
-
if (this.
|
|
195
|
-
this.shellBind.
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
194
|
+
if (this.feedback.socket) {
|
|
195
|
+
if (this.shellBind.has(uuid)) {
|
|
196
|
+
this.shellBind.get(uuid).push(this.feedback.socket);
|
|
197
|
+
}
|
|
198
|
+
else {
|
|
199
|
+
this.shellBind.set(uuid, [this.feedback.socket]);
|
|
200
|
+
}
|
|
199
201
|
}
|
|
200
202
|
};
|
|
201
203
|
shell_close = (socket, uuid) => {
|
|
202
204
|
this.websocket_manager.shell_close(uuid);
|
|
203
|
-
if (this.
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
205
|
+
if (this.feedback.socket) {
|
|
206
|
+
if (this.shellBind.has(uuid)) {
|
|
207
|
+
const p = this.shellBind.get(uuid);
|
|
208
|
+
const index = p.findIndex(x => x == this.feedback.socket);
|
|
209
|
+
if (index != -1)
|
|
210
|
+
p.splice(index, 1);
|
|
211
|
+
this.shellBind.set(uuid, p);
|
|
212
|
+
}
|
|
209
213
|
}
|
|
210
214
|
};
|
|
211
215
|
shell_folder = (socket, uuid, path) => {
|
package/package.json
CHANGED
package/src/server/detail.ts
CHANGED
|
@@ -278,19 +278,23 @@ export class ServerDetail {
|
|
|
278
278
|
}
|
|
279
279
|
shell_open = (socket:any, uuid: string) => {
|
|
280
280
|
this.websocket_manager!.shell_open(uuid)
|
|
281
|
-
if(this.
|
|
282
|
-
this.shellBind.
|
|
283
|
-
|
|
284
|
-
|
|
281
|
+
if(this.feedback.socket){
|
|
282
|
+
if(this.shellBind.has(uuid)){
|
|
283
|
+
this.shellBind.get(uuid).push(this.feedback.socket)
|
|
284
|
+
}else{
|
|
285
|
+
this.shellBind.set(uuid, [this.feedback.socket])
|
|
286
|
+
}
|
|
285
287
|
}
|
|
286
288
|
}
|
|
287
289
|
shell_close = (socket:any, uuid: string) => {
|
|
288
290
|
this.websocket_manager!.shell_close(uuid)
|
|
289
|
-
if(this.
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
291
|
+
if(this.feedback.socket){
|
|
292
|
+
if(this.shellBind.has(uuid)){
|
|
293
|
+
const p:Array<any> = this.shellBind.get(uuid)
|
|
294
|
+
const index = p.findIndex(x => x == this.feedback.socket)
|
|
295
|
+
if(index != -1) p.splice(index, 1)
|
|
296
|
+
this.shellBind.set(uuid, p)
|
|
297
|
+
}
|
|
294
298
|
}
|
|
295
299
|
}
|
|
296
300
|
shell_folder = (socket:any, uuid: string, path:string) => {
|