protected function renderSerializerException(BaseSerializerException $error) {
		if ($this->isJsonApiRequest()) {
			return $this->renderSerializerAsJsonApi($error);
		}

		if ($this->isJsonRequest()) {
			return $this->renderSerializerAsJson($error);
		}

		return $this->defaultSerializerRender($error);
	}