add secure parameter to force https

This commit is contained in:
Nicolas Surleraux
2018-05-26 13:27:58 +02:00
parent d9fca62c17
commit 307ce9a53f
3 changed files with 16 additions and 3 deletions
+2 -1
View File
@@ -28,7 +28,7 @@ class ClientManager {
// create a new tunnel with `id`
// if the id is already used, a random id is assigned
// if the tunnel could not be created, throws an error
async newClient(id) {
async newClient(id, secure) {
const clients = this.clients;
const stats = this.stats;
@@ -46,6 +46,7 @@ class ClientManager {
const client = new Client({
id,
agent,
secure,
});
// add to clients map immediately