[ofbiz-framework] branch release18.12 updated: Multi Part Input Parameters not Available in Groovy Event (OFBIZ-5048)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[ofbiz-framework] branch release18.12 updated: Multi Part Input Parameters not Available in Groovy Event (OFBIZ-5048)

mbrohl
This is an automated email from the ASF dual-hosted git repository.

mbrohl pushed a commit to branch release18.12
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git


The following commit(s) were added to refs/heads/release18.12 by this push:
     new 02d59bc  Multi Part Input Parameters not Available in Groovy Event (OFBIZ-5048)
02d59bc is described below

commit 02d59bcd5b0b9040a2fda777d26c0879139ae646
Author: Michael Brohl <[hidden email]>
AuthorDate: Fri Jan 31 15:52:51 2020 +0100

    Multi Part Input Parameters not Available in Groovy Event
    (OFBIZ-5048)
   
    This change provides easier access to the FileItem by not wrapping it
    into a buffer.
---
 framework/base/src/main/java/org/apache/ofbiz/base/util/UtilHttp.java | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/framework/base/src/main/java/org/apache/ofbiz/base/util/UtilHttp.java b/framework/base/src/main/java/org/apache/ofbiz/base/util/UtilHttp.java
index 7bae1ec..49ff74e 100644
--- a/framework/base/src/main/java/org/apache/ofbiz/base/util/UtilHttp.java
+++ b/framework/base/src/main/java/org/apache/ofbiz/base/util/UtilHttp.java
@@ -275,7 +275,7 @@ public final class UtilHttp {
                                 fileName = fileName.substring(lastIndex + 1);
                             }
                         }
-                        multiPartMap.put(fieldName, ByteBuffer.wrap(item.get()));
+                        multiPartMap.put(fieldName, item);
                         multiPartMap.put("_" + fieldName + "_size", item.getSize());
                         multiPartMap.put("_" + fieldName + "_fileName", fileName);
                         multiPartMap.put("_" + fieldName + "_contentType", item.getContentType());