From 032ea51e0d7c4362facb28ee590b8fad21271c59 Mon Sep 17 00:00:00 2001 From: Martin Juzl Date: Thu, 12 Sep 2024 17:19:27 +0200 Subject: [PATCH] Update Client.ProcessResponse.HandleStatusCode.liquid --- .../modules/Client.ProcessResponse.HandleStatusCode.liquid | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/templates/modules/Client.ProcessResponse.HandleStatusCode.liquid b/src/templates/modules/Client.ProcessResponse.HandleStatusCode.liquid index 4313f9c..4e1c66e 100644 --- a/src/templates/modules/Client.ProcessResponse.HandleStatusCode.liquid +++ b/src/templates/modules/Client.ProcessResponse.HandleStatusCode.liquid @@ -106,7 +106,11 @@ return{% if operation.HasResultType %} null{% endif %}; {% endif -%} {% endif -%} {% else -%} +{% if response.StatusCode == "204" -%} +return Promise.resolve(null as any); +{% else -%} return throwException({% if Framework.IsAngularJS %}this.q, {% endif %}"{{ response.ExceptionDescription }}", status, _responseText, _headers); +{% endif -%} {% endif -%} {% template Client.ProcessResponse.ReadBodyEnd %} {% endif -%}