protected function connectWs()
    {
        $this->logger->info('starting connection to websocket', ['gateway' => $this->gateway]);

        $this->wsFactory->__invoke($this->gateway)->then(
            [$this, 'handleWsConnection'],
            [$this, 'handleWsError']
        );
    }
protected function connectWs()
    {
        $this->logger->info('starting connection to websocket', ['gateway' => $this->gateway]);

        $this->wsFactory->__invoke($this->gateway)->then(
            [$this, 'handleWsConnection'],
            [$this, 'handleWsError']
        );
    }
protected function connectWs ( ) { $ this -> logger -> info ( 'starting connection to websocket' , [ 'gateway' => $ this -> gateway ] ) ; $ this -> wsFactory -> __invoke ( $ this -> gateway ) -> then ( [ $ this , 'handleWsConnection' ] , [ $ this , 'handleWsError' ] ) ; }
Initilizes the connection with the Discord gateway.

@return void
Initilizes the connection with the Discord gateway .