You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by jb...@apache.org on 2007/03/09 22:41:23 UTC

svn commit: r516562 - /incubator/wicket/branches/wicket-1.x/wicket/src/main/java/wicket/protocol/http/WebResponse.java

Author: jbq
Date: Fri Mar  9 13:41:23 2007
New Revision: 516562

URL: http://svn.apache.org/viewvc?view=rev&rev=516562
Log:
WICKET-313 Use standard exception handling in AjaxRequestTarget

Do not set SC_OK status code here, SC_INTERNAL_ERROR should not be there in the
first place.  The problem is fixed properly in revision 516552 in
BufferedHttpServletResponse

Modified:
    incubator/wicket/branches/wicket-1.x/wicket/src/main/java/wicket/protocol/http/WebResponse.java

Modified: incubator/wicket/branches/wicket-1.x/wicket/src/main/java/wicket/protocol/http/WebResponse.java
URL: http://svn.apache.org/viewvc/incubator/wicket/branches/wicket-1.x/wicket/src/main/java/wicket/protocol/http/WebResponse.java?view=diff&rev=516562&r1=516561&r2=516562
==============================================================================
--- incubator/wicket/branches/wicket-1.x/wicket/src/main/java/wicket/protocol/http/WebResponse.java (original)
+++ incubator/wicket/branches/wicket-1.x/wicket/src/main/java/wicket/protocol/http/WebResponse.java Fri Mar  9 13:41:23 2007
@@ -192,10 +192,11 @@
 
 					if (isAjax())
 					{
-						// Reset the HTTP response status code to 200, otherwise
-						// wicket-ajax.js does not process the Ajax-Location
-						// header
-						httpServletResponse.setStatus(HttpServletResponse.SC_OK);
+						/*
+						 * By reaching this point, make sure the HTTP response
+						 * status code is set to 200, otherwise wicket-ajax.js
+						 * will not process the Ajax-Location header
+						 */
 						httpServletResponse.addHeader("Ajax-Location", url);
 
 						// safari chokes on empty response. but perhaps this is