private function handleSubscription(ConnectionInterface $from, $data) {
    if (isset($data['query'])) {
      // Request is for a query.

      $this->handleSubscriptionQuery($from, $data);
    } elseif (isset($data['uid']) && is_string($data['uid'])) {
      // Request is for a UID.

      $this->handleSubscriptionUid($from, $data);
    }
  }
private function handleSubscription(ConnectionInterface $from, $data) {
    if (isset($data['query'])) {
      // Request is for a query.

      $this->handleSubscriptionQuery($from, $data);
    } elseif (isset($data['uid']) && is_string($data['uid'])) {
      // Request is for a UID.

      $this->handleSubscriptionUid($from, $data);
    }
  }
private function handleSubscription ( ConnectionInterface $ from , $ data ) { if ( isset ( $ data [ 'query' ] ) ) { // Request is for a query. $ this -> handleSubscriptionQuery ( $ from , $ data ) ; } elseif ( isset ( $ data [ 'uid' ] ) && is_string ( $ data [ 'uid' ] ) ) { // Request is for a UID. $ this -> handleSubscriptionUid ( $ from , $ data ) ; } }
Handle a subscribe or unsubscribe from a client.

@param ConnectionInterface $from
@param array $data
Handle a subscribe or unsubscribe from a client .