[OFBIZ-2618] Applying patch contributed by Arun Patidar. Thanks Arun for updated fix. Thanks BJ for reporting the issue and providing first patch.