public function onClose(ConnectionInterface $connection)
    {
        $client = $this->clients->findByConnection($connection);

        if ($client) {
            $this->clients->remove($client);

            $this->command->info('Client disconnected');

            // Fire the event.
            Event::fire(new ClientDisconnected($this->server, $this->clients, $client));
        }
    }
public function onClose(ConnectionInterface $connection)
    {
        $client = $this->clients->findByConnection($connection);

        if ($client) {
            $this->clients->remove($client);

            $this->command->info('Client disconnected');

            // Fire the event.
            Event::fire(new ClientDisconnected($this->server, $this->clients, $client));
        }
    }
public function onClose ( ConnectionInterface $ connection ) { $ client = $ this -> clients -> findByConnection ( $ connection ) ; if ( $ client ) { $ this -> clients -> remove ( $ client ) ; $ this -> command -> info ( 'Client disconnected' ) ; // Fire the event. Event :: fire ( new ClientDisconnected ( $ this -> server , $ this -> clients , $ client ) ) ; } }
Client disconnected.
Client disconnected .