svn commit: r1101373 - /ofbiz/trunk/applications/product/src/org/ofbiz/product/product/ProductServices.java

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

svn commit: r1101373 - /ofbiz/trunk/applications/product/src/org/ofbiz/product/product/ProductServices.java

lektran
Author: lektran
Date: Tue May 10 09:23:07 2011
New Revision: 1101373

URL: http://svn.apache.org/viewvc?rev=1101373&view=rev
Log:
[OFBIZ-4273] Change FastSet back to HashSet since a FastSet throws an NPE when attempting to add null to the collection.  Fixes bug reported by Sam Hamilton, attempting to use the quickCreateVirtualWithVariants service returns an error

Modified:
    ofbiz/trunk/applications/product/src/org/ofbiz/product/product/ProductServices.java

Modified: ofbiz/trunk/applications/product/src/org/ofbiz/product/product/ProductServices.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/product/src/org/ofbiz/product/product/ProductServices.java?rev=1101373&r1=1101372&r2=1101373&view=diff
==============================================================================
--- ofbiz/trunk/applications/product/src/org/ofbiz/product/product/ProductServices.java (original)
+++ ofbiz/trunk/applications/product/src/org/ofbiz/product/product/ProductServices.java Tue May 10 09:23:07 2011
@@ -28,6 +28,7 @@ import java.math.BigDecimal;
 import java.nio.ByteBuffer;
 import java.sql.Timestamp;
 import java.util.Arrays;
+import java.util.HashSet;
 import java.util.LinkedHashMap;
 import java.util.LinkedHashSet;
 import java.util.List;
@@ -870,7 +871,7 @@ public class ProductServices {
             Set<String> featureProductIds = FastSet.newInstance();
             featureProductIds.add(productId);
             featureProductIds.addAll(variantProductsById.keySet());
-            Set<String> productFeatureIds = FastSet.newInstance();
+            Set<String> productFeatureIds = new HashSet<String>();
             productFeatureIds.add(productFeatureIdOne);
             productFeatureIds.add(productFeatureIdTwo);
             productFeatureIds.add(productFeatureIdThree);