diff --git a/library/server/ewsgi/specification/response/wgi_response.e b/library/server/ewsgi/specification/response/wgi_response.e index e24829d1..ba00703a 100644 --- a/library/server/ewsgi/specification/response/wgi_response.e +++ b/library/server/ewsgi/specification/response/wgi_response.e @@ -19,6 +19,14 @@ feature {WGI_CONNECTOR, WGI_SERVICE} -- Commit feature -- Status report + status_committed: BOOLEAN + -- Is status code set and committed? + -- i.e: sent to the client and could not be changed anymore + deferred + ensure + committed_implies_set: Result implies status_is_set + end + header_committed: BOOLEAN -- Header committed? deferred @@ -49,19 +57,11 @@ feature -- Status setting deferred end - status_committed: BOOLEAN - -- Is status code set and committed? - -- i.e: sent to the client and could not be changed anymore - deferred - ensure - committed_implies_set: Result implies status_is_set - end - set_status_code (a_code: INTEGER) -- Set response status code -- Should be done before sending any data back to the client require - status_not_set: not status_is_set + status_not_set: not status_committed header_not_committed: not header_committed deferred ensure diff --git a/library/server/wsf/src/wsf_response.e b/library/server/wsf/src/wsf_response.e index d9e5925f..f8bfcfc6 100644 --- a/library/server/wsf/src/wsf_response.e +++ b/library/server/wsf/src/wsf_response.e @@ -94,7 +94,7 @@ feature -- Header output operation put_header (a_status_code: INTEGER; a_headers: detachable ARRAY [TUPLE [key: READABLE_STRING_8; value: READABLE_STRING_8]]) -- Send headers with status `a_status', and headers from `a_headers' require - status_not_set: not status_is_set + status_not_committed: not status_committed header_not_committed: not header_committed local h: HTTP_HEADER