|
@@ -17,9 +17,9 @@ function stripAfterEquals(str:string):string{
|
17
|
17
|
* A websocket-on-steroids with built-in RPC capabilities
|
18
|
18
|
*/
|
19
|
19
|
export class RPCSocket implements I.Socket{
|
20
|
|
- static async makeSocket<T extends T.RPCInterface= T.RPCInterface>(port:number, server: string, conf?:T.SocketConf): Promise<RPCSocket & T.RPCInterface<T>> {
|
|
20
|
+ static async makeSocket<T extends T.RPCInterface= T.RPCInterface>(port:number, server: string, sesame?:string, conf?:T.SocketConf): Promise<RPCSocket & T.RPCInterface<T>> {
|
21
|
21
|
const socket = <RPCSocket & T> new RPCSocket(port, server, conf)
|
22
|
|
- return await socket.connect<T>()
|
|
22
|
+ return await socket.connect<T>(sesame)
|
23
|
23
|
}
|
24
|
24
|
|
25
|
25
|
private socket: I.Socket
|