diff --git a/modules/openapi-generator/src/main/resources/cpp-ue4/api-source.mustache b/modules/openapi-generator/src/main/resources/cpp-ue4/api-source.mustache index c1ca56649e5..58d2bc7656a 100644 --- a/modules/openapi-generator/src/main/resources/cpp-ue4/api-source.mustache +++ b/modules/openapi-generator/src/main/resources/cpp-ue4/api-source.mustache @@ -56,7 +56,11 @@ void {{classname}}::HandleResponse(FHttpResponsePtr HttpResponse, bool bSucceede FString ContentType = HttpResponse->GetContentType(); FString Content; - if (ContentType == TEXT("application/json")) + if(ContentType.IsEmpty()) + { + return; // Nothing to parse + } + else if (ContentType == TEXT("application/json")) { Content = HttpResponse->GetContentAsString();