Skip to content

Commit b9df405

Browse files
authored
Merge pull request #10 from BlueAcornInc/release-20.1.0
Fix Issue #4
2 parents b6f8353 + 2606a16 commit b9df405

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

cartridges/int_kount/cartridge/scripts/kount/libKount.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -501,7 +501,7 @@ function postRIS(order, isSfra, isPreRiskCall) {
501501
return hashedCCNumber === item.custom.kount_KHash;
502502
});
503503
last4 = paymentInstrument ? paymentInstrument.creditCardNumber.substr(paymentInstrument.creditCardNumber.length - 4) : '';
504-
} else {
504+
} else if (creditCardNumber) {
505505
last4 = creditCardNumber.substr(creditCardNumber.length - 4);
506506
hashedCCNumber = KHash.hashPaymentToken(creditCardNumber); // else hash CC number from form
507507
}

cartridges/int_kount/cartridge/scripts/kount/postRiskInqueryService.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ function init(args, preRiskCall) {
5353
BML: '',
5454
CREDIT_CARD: creditCard.HashedCardNumber,
5555
GIFT_CERTIFICATE: payInstr ? KHash.hashGiftCard(payInstr.getGiftCertificateCode()) : '',
56-
PayPal: payInstr && 'paypalPayerID' in payInstr.custom && !empty(payInstr.custom.paypalPayerID) ? payInstr.custom.paypalPayerID : ''
56+
PayPal: payInstr && 'paypalPayerID' in payInstr.custom && !empty(payInstr.custom.paypalPayerID) ? KHash.hash(payInstr.custom.paypalPayerID) : ''
5757
};
5858
var paymentType = 'NONE';
5959
var paymentToken = null;

test/unit/int_kount/scripts/kount/postRiskInqueryService.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -296,6 +296,9 @@ describe('PostRiskInqueryService', function () {
296296
'*/cartridge/scripts/kount/kHash': {
297297
hashGiftCard: function (data) {
298298
return data;
299+
},
300+
hash: function (data) {
301+
return data;
299302
}
300303
}
301304
});

0 commit comments

Comments
 (0)