Anil, please look at my earlier commit..... i do not even think that your change alone does not solve the problem.....the problem is not the context but the record not having a status.....
regards, Hans On Mon, 2009-06-08 at 05:35 +0000, apa...@apache.org wrote: > Author: apatel > Date: Mon Jun 8 05:35:18 2009 > New Revision: 782530 > > URL: http://svn.apache.org/viewvc?rev=782530&view=rev > Log: > Fix NPE if statusId is not passed to service. > > Modified: > > ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyServices.java > > Modified: > ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyServices.java > URL: > http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyServices.java?rev=782530&r1=782529&r2=782530&view=diff > ============================================================================== > --- > ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyServices.java > (original) > +++ > ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyServices.java > Mon Jun 8 05:35:18 2009 > @@ -306,7 +306,7 @@ > return > ServiceUtil.returnError(UtilProperties.getMessage(resource, > "person.update.write_failure", new Object[] { e.getMessage() }, locale)); > } > > - if (!context.get("statusId").equals(oldStatusId)) { > + if (UtilValidate.isNotEmpty(context.get("statusId")) && > !context.get("statusId").equals(oldStatusId)) { > try { > dispatcher.runSync("setPartyStatus", > UtilMisc.toMap("partyId", partyId, "statusId", context.get("statusId"), > "userLogin", context.get("userLogin"))); > } catch (GenericServiceException e) { > > -- Antwebsystems.com: Quality OFBiz services for competitive rates