public function __destruct() { if ($this->ch) { $this->ch->close(); } if ($this->conn->isConnected()) { $this->conn->close(); } }
/** * @param string $id * @return Channel */ protected function doCreateChannel($id) { $channel = new Channel($this->connection, $id); if ($this->panel) { $channel->injectPanel($this->panel); } return $channel; }