[client] hostname from environ

This commit is contained in:
2018-03-28 17:30:42 +03:00
parent 6d2a1a002b
commit c8448b7848
4 changed files with 33 additions and 5 deletions

View File

@@ -30,7 +30,7 @@ class JsConnection<O:Message, I:Message> extends BaseConnection<O, I> {
}
private function buildSocket(host:String, port:Int):WebSocket {
return untyped __js__('new WebSocket("ws://${host}:${port}");');
return untyped __js__("new WebSocket('ws://'+host+':'+port);");
}
override public function connect():Promise<IConnection<O, I>> {