[ 
https://issues.apache.org/jira/browse/OFBIZ-3478?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12834079#action_12834079
 ] 

Amit Sharma commented on OFBIZ-3478:
------------------------------------

Thanks Scott for your comment.

As the this.reservLength is initializing to BigDecimal.ZERO and reservLength is 
passed in the method and might be null so the appropriate check for this should 
be 

{code}

if (bigDecimal2 != null && bigDecimal1.compareTo(bigDecimal2) != 0) {

{code}

Please let me know your thought.

-Amit Sharma

> Compares the specified object with this cart item is not in the right way.
> --------------------------------------------------------------------------
>
>                 Key: OFBIZ-3478
>                 URL: https://issues.apache.org/jira/browse/OFBIZ-3478
>             Project: OFBiz
>          Issue Type: Bug
>          Components: order
>    Affects Versions: SVN trunk
>            Reporter: Amit Sharma
>             Fix For: SVN trunk
>
>         Attachments: OFBIZ-3478.patch
>
>
> In ShoppingCartItem.java compares of the specified object with this cart item 
> is not in the right way.
> It should be
> if (!this.reservLength.equals(reservLength)) {
>    return false;
> }
> instead of 
> if (this.reservLength != reservLength) {
>    return false;
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to