Author: lektran
Date: Wed Aug 4 04:17:08 2010
New Revision: 982117
URL:
http://svn.apache.org/viewvc?rev=982117&view=revLog:
Prevent potential NPE
Modified:
ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyWorker.java
Modified: ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyWorker.java
URL:
http://svn.apache.org/viewvc/ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyWorker.java?rev=982117&r1=982116&r2=982117&view=diff==============================================================================
--- ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyWorker.java (original)
+++ ofbiz/trunk/applications/party/src/org/ofbiz/party/party/PartyWorker.java Wed Aug 4 04:17:08 2010
@@ -97,7 +97,7 @@ public class PartyWorker {
// generate the sequenced number and pad
Long seq = delegator.getNextSeqIdLong(clubSeqName);
- clubId = clubId + UtilFormatOut.formatPaddedNumber(seq.longValue(), (length - prefix.length() - 1));
+ clubId = clubId + UtilFormatOut.formatPaddedNumber(seq.longValue(), (length - clubId.length() - 1));
// get the check digit
int check = UtilValidate.getLuhnCheckDigit(clubId);