protected function getResponse() { if ($this->sent) { return $this->response; } throw new \RuntimeException("Attempt to get response data when request hasn't been sent yet"); }