public function listen($errorHandler = null)
    {
        if ($this->handler instanceof \Closure) {
            $this->handler = $this->handler->bindTo($this);
        }

        $response = call_user_func($this->handler, $this->request, $this->response, $errorHandler);

        if (!$response instanceof ResponseInterface) {
            $response = $this->response;
        }

        $this->output->respond($response);
    }