Scott:

I will look at this a bit later, but one cannot assume ids are integers now. What was the behavior that forces this revert so that I can verify a better fix?

Thanks,

Randy

[email protected] wrote:
Author: scottbw
Date: Fri Jun 18 09:43:56 2010
New Revision: 955912

URL: http://svn.apache.org/viewvc?rev=955912&view=rev
Log:
Fixed issue with the Widgets Controller - was using wrong logic for determining 
resource validity. I'm not sure how this bug got introduced though. WOOKIE-144

Modified:
    
incubator/wookie/branches/pluggablepersistence/src/org/apache/wookie/controller/WidgetsController.java

Modified: 
incubator/wookie/branches/pluggablepersistence/src/org/apache/wookie/controller/WidgetsController.java
URL: 
http://svn.apache.org/viewvc/incubator/wookie/branches/pluggablepersistence/src/org/apache/wookie/controller/WidgetsController.java?rev=955912&r1=955911&r2=955912&view=diff
==============================================================================
--- 
incubator/wookie/branches/pluggablepersistence/src/org/apache/wookie/controller/WidgetsController.java
 (original)
+++ 
incubator/wookie/branches/pluggablepersistence/src/org/apache/wookie/controller/WidgetsController.java
 Fri Jun 18 09:43:56 2010
@@ -69,8 +69,8 @@ public class WidgetsController extends C
         * @see org.apache.wookie.controller.Controller#show(java.lang.String, 
javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)
         */
        protected void show(String resourceId, HttpServletRequest request,
-                       HttpServletResponse response) throws 
ResourceNotFoundException, IOException {
-               if ((resourceId != null) && (resourceId.length() > 0)){
+                       HttpServletResponse response) throws 
ResourceNotFoundException, IOException {           
+               if (!isAnInteger(resourceId)){
                        index(resourceId, request, response);
                        return;
                }




Reply via email to