svn commit: r790133 - /ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java

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

svn commit: r790133 - /ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java

lektran
Author: lektran
Date: Wed Jul  1 12:04:05 2009
New Revision: 790133

URL: http://svn.apache.org/viewvc?rev=790133&view=rev
Log:
Avoid NPE

Modified:
    ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java

Modified: ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java?rev=790133&r1=790132&r2=790133&view=diff
==============================================================================
--- ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java (original)
+++ ofbiz/trunk/applications/order/src/org/ofbiz/order/shoppingcart/ShoppingCart.java Wed Jul  1 12:04:05 2009
@@ -3458,7 +3458,9 @@
                 orderItem.set("shipAfterDate", item.getShipAfterDate());
                 orderItem.set("estimatedShipDate", item.getEstimatedShipDate());
                 orderItem.set("cancelBackOrderDate", item.getCancelBackOrderDate());
-                orderItem.set("changeByUserLoginId", this.getUserLogin().get("userLoginId"));
+                if (this.getUserLogin() != null) {
+                    orderItem.set("changeByUserLoginId", this.getUserLogin().get("userLoginId"));
+                }
 
                 String fromInventoryItemId = (String) item.getAttribute("fromInventoryItemId");
                 if (fromInventoryItemId != null) {