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 d2821b2daaa..8d0efb6a1d9 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,6 +56,7 @@ void {{classname}}::SetHttpRetryManager(FHttpRetrySystem::FManager& InRetryManag FHttpRetrySystem::FManager& {{classname}}::GetHttpRetryManager() { + checkf(RetryManager, TEXT("{{classname}}: RetryManager is null. You may have meant to set it with SetHttpRetryManager first, or you may not be using a custom RetryManager at all.")) return *RetryManager; } diff --git a/samples/client/petstore/cpp-ue4/Private/OpenAPIPetApi.cpp b/samples/client/petstore/cpp-ue4/Private/OpenAPIPetApi.cpp index ec0444e643c..3e52679fc3e 100644 --- a/samples/client/petstore/cpp-ue4/Private/OpenAPIPetApi.cpp +++ b/samples/client/petstore/cpp-ue4/Private/OpenAPIPetApi.cpp @@ -65,6 +65,7 @@ void OpenAPIPetApi::SetHttpRetryManager(FHttpRetrySystem::FManager& InRetryManag FHttpRetrySystem::FManager& OpenAPIPetApi::GetHttpRetryManager() { + checkf(RetryManager, TEXT("OpenAPIPetApi: RetryManager is null. You may have meant to set it with SetHttpRetryManager first, or you may not be using a custom RetryManager at all.")) return *RetryManager; } diff --git a/samples/client/petstore/cpp-ue4/Private/OpenAPIStoreApi.cpp b/samples/client/petstore/cpp-ue4/Private/OpenAPIStoreApi.cpp index 1c5935b0867..04ee754d255 100644 --- a/samples/client/petstore/cpp-ue4/Private/OpenAPIStoreApi.cpp +++ b/samples/client/petstore/cpp-ue4/Private/OpenAPIStoreApi.cpp @@ -65,6 +65,7 @@ void OpenAPIStoreApi::SetHttpRetryManager(FHttpRetrySystem::FManager& InRetryMan FHttpRetrySystem::FManager& OpenAPIStoreApi::GetHttpRetryManager() { + checkf(RetryManager, TEXT("OpenAPIStoreApi: RetryManager is null. You may have meant to set it with SetHttpRetryManager first, or you may not be using a custom RetryManager at all.")) return *RetryManager; } diff --git a/samples/client/petstore/cpp-ue4/Private/OpenAPIUserApi.cpp b/samples/client/petstore/cpp-ue4/Private/OpenAPIUserApi.cpp index 55b34981cb5..cc231f0be31 100644 --- a/samples/client/petstore/cpp-ue4/Private/OpenAPIUserApi.cpp +++ b/samples/client/petstore/cpp-ue4/Private/OpenAPIUserApi.cpp @@ -65,6 +65,7 @@ void OpenAPIUserApi::SetHttpRetryManager(FHttpRetrySystem::FManager& InRetryMana FHttpRetrySystem::FManager& OpenAPIUserApi::GetHttpRetryManager() { + checkf(RetryManager, TEXT("OpenAPIUserApi: RetryManager is null. You may have meant to set it with SetHttpRetryManager first, or you may not be using a custom RetryManager at all.")) return *RetryManager; }