From 456299ccdf1d5fd6ac33a0904112c7473722ff1a Mon Sep 17 00:00:00 2001 From: Jocelyn Fiat Date: Tue, 4 Oct 2011 17:33:15 +0200 Subject: [PATCH] Fixed agent handler for rest library --- .../request/rest/src/rest_request_agent_handler.e | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/library/server/request/rest/src/rest_request_agent_handler.e b/library/server/request/rest/src/rest_request_agent_handler.e index 0a14298e..299ea78d 100644 --- a/library/server/request/rest/src/rest_request_agent_handler.e +++ b/library/server/request/rest/src/rest_request_agent_handler.e @@ -42,7 +42,15 @@ feature -- Execution execute (ctx: C; req: WGI_REQUEST; res: WGI_RESPONSE_BUFFER) do - Precursor {REQUEST_AGENT_HANDLER} (ctx, req, res) + if + authentication_required (req) and then not authenticated (ctx) + then + execute_unauthorized (ctx, req, res) + else + pre_execute (ctx, req, res) + Precursor {REQUEST_AGENT_HANDLER} (ctx, req, res) + post_execute (ctx, req, res) + end end execute_application (ctx: C; req: WGI_REQUEST; res: WGI_RESPONSE_BUFFER)