Minor fixes
parent
1383af2646
commit
1ee93c5715
|
@ -64,6 +64,7 @@ export class Client {
|
||||||
|
|
||||||
handle_close() {
|
handle_close() {
|
||||||
this.socket = null;
|
this.socket = null;
|
||||||
|
this.close();
|
||||||
}
|
}
|
||||||
|
|
||||||
handle_message(buffer, isBinary) {
|
handle_message(buffer, isBinary) {
|
||||||
|
|
3
vpn.js
3
vpn.js
|
@ -57,7 +57,7 @@ class VPNTarget {
|
||||||
}
|
}
|
||||||
this.addr = `${this.ip}:${this.bindport}`;
|
this.addr = `${this.ip}:${this.bindport}`;
|
||||||
vpn.targets.set(this.addr, this);
|
vpn.targets.set(this.addr, this);
|
||||||
client.log("VPN connect to ${this.addr}");
|
client.log(`VPN connect to ${this.addr}`);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Forward a message from the client
|
// Forward a message from the client
|
||||||
|
@ -92,6 +92,7 @@ class VPNTarget {
|
||||||
}
|
}
|
||||||
|
|
||||||
close() {
|
close() {
|
||||||
|
this.vpn.targets.delete(this.addr);
|
||||||
this.client.close();
|
this.client.close();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue