You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@turbine.apache.org by sg...@apache.org on 2007/05/13 22:37:41 UTC

svn commit: r537656 - /jakarta/turbine/fulcrum/trunk/parser/src/java/org/apache/fulcrum/parser/BaseValueParser.java

Author: sgoeschl
Date: Sun May 13 13:37:40 2007
New Revision: 537656

URL: http://svn.apache.org/viewvc?view=rev&rev=537656
Log:
Temporay fix for broken test case - according to TV the implementation of the service needs to improved to match the original turbine implementation. The original implementation had two maps for for name/value pairs and one for FileUpload thingies but in the current implementation we have only one map inviting class cast exceptions

Modified:
    jakarta/turbine/fulcrum/trunk/parser/src/java/org/apache/fulcrum/parser/BaseValueParser.java

Modified: jakarta/turbine/fulcrum/trunk/parser/src/java/org/apache/fulcrum/parser/BaseValueParser.java
URL: http://svn.apache.org/viewvc/jakarta/turbine/fulcrum/trunk/parser/src/java/org/apache/fulcrum/parser/BaseValueParser.java?view=diff&rev=537656&r1=537655&r2=537656
==============================================================================
--- jakarta/turbine/fulcrum/trunk/parser/src/java/org/apache/fulcrum/parser/BaseValueParser.java (original)
+++ jakarta/turbine/fulcrum/trunk/parser/src/java/org/apache/fulcrum/parser/BaseValueParser.java Sun May 13 13:37:40 2007
@@ -1539,8 +1539,18 @@
     protected String [] getParam(final String name)
     {
         String key = convert(name);
-
-        return (key != null) ? (String []) parameters.get(key) : null;
+        Object value = parameters.get(key);
+        
+        // todo sgoeschl 20070405 quick fix for Scott's test case - need to
+        // be reworked for proper functioning according to TV
+        if(value instanceof String[])
+        {
+            return (String []) parameters.get(key);
+        }
+        else
+        {
+            return null;
+        }
     }
 
 



---------------------------------------------------------------------
To unsubscribe, e-mail: turbine-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: turbine-dev-help@jakarta.apache.org