[freeside-commits] branch FREESIDE_3_BRANCH_71513 updated. 2a565ea54a0af5f32ac26804be62249effa958bf
Jonathan Prykop
jonathan at 420.am
Mon Dec 12 12:08:05 PST 2016
The branch, FREESIDE_3_BRANCH_71513 has been updated
via 2a565ea54a0af5f32ac26804be62249effa958bf (commit)
from 3a4594911a30cfcc7a27f91b1b22721ff981a0a7 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 2a565ea54a0af5f32ac26804be62249effa958bf
Author: Jonathan Prykop <jonathan at freeside.biz>
Date: Mon Dec 12 13:33:29 2016 -0600
RT#71513: Card tokenization [v3 bug fixes]
diff --git a/FS/FS/cust_main/Billing_Realtime.pm b/FS/FS/cust_main/Billing_Realtime.pm
index cf32a29..453cd71 100644
--- a/FS/FS/cust_main/Billing_Realtime.pm
+++ b/FS/FS/cust_main/Billing_Realtime.pm
@@ -779,16 +779,15 @@ sub realtime_bop {
# This block will only run if the B::OP module supports card_token but not the Tokenize transaction;
# if that never happens, we should get rid of it (as it has the potential to store real card numbers on error)
- if ( $transaction->can('card_token') && $transaction->card_token ) {
- if ( $options{'payinfo'} eq $self->payinfo ) {
- $self->payinfo($transaction->card_token);
- my $error = $self->replace;
- if ( $error ) {
- $log->critical('Error storing token for cust '.$self->custnum.': '.$error);
- #not returning error, should at least attempt to handle results of an otherwise valid transaction
- #this leaves real card number in cust_main, but can't do much else if cust_main won't replace
- warn "WARNING: error storing token: $error, but proceeding anyway\n";
- }
+ if (my $card_token = $self->_tokenize_card($transaction,\%options)) {
+ # cpp will be replaced in _realtime_bop_result
+ $cust_pay_pending->payinfo($card_token);
+ my $error = $self->replace;
+ if ( $error ) {
+ $log->critical('Error storing token for cust '.$self->custnum.': '.$error);
+ #not returning error, should at least attempt to handle results of an otherwise valid transaction
+ #this leaves real card number in cust_main, but can't do much else if cust_main won't replace
+ warn "WARNING: error storing token: $error, but proceeding anyway\n";
}
}
-----------------------------------------------------------------------
Summary of changes:
FS/FS/cust_main/Billing_Realtime.pm | 19 +++++++++----------
1 file changed, 9 insertions(+), 10 deletions(-)
More information about the freeside-commits
mailing list