fix a "false success" problem caused by discrepancy between test and live systems... Business_OnlinePayment_TransactionCentral_0_04
authorivan <ivan>
Wed, 30 May 2007 18:55:09 +0000 (18:55 +0000)
committerivan <ivan>
Wed, 30 May 2007 18:55:09 +0000 (18:55 +0000)
Changes
lib/Business/OnlinePayment/TransactionCentral.pm

diff --git a/Changes b/Changes
index 11b08da..547b726 100644 (file)
--- a/Changes
+++ b/Changes
@@ -1,7 +1,9 @@
 Revision history for Perl extension Business::OnlinePayment::TransactionCentral.
 
 Revision history for Perl extension Business::OnlinePayment::TransactionCentral.
 
-0.04  unreleased
+0.04  Wed May 30 11:53:00 PDT 2007
         - depend on B:OP v3
         - depend on B:OP v3
+        - fix a "false success" problem caused by discrepancy between test and
+          live systems: "Auth" field comes back as "Declined" rather than empty
 
 0.03  Sat May 19 15:03:43 PDT 2007
         - add/finish ECHECK support (google of TCInterfaceGuide indicated
 
 0.03  Sat May 19 15:03:43 PDT 2007
         - add/finish ECHECK support (google of TCInterfaceGuide indicated
index 1e96722..c9d7653 100644 (file)
@@ -140,7 +140,7 @@ sub submit {
   $self->avs_code(      $return{'AVSCode'} );
   $self->cvv2_response( $return{'CVV2ResponseMsg'} );
 
   $self->avs_code(      $return{'AVSCode'} );
   $self->cvv2_response( $return{'CVV2ResponseMsg'} );
 
-  if ( $return{'Auth'} =~ /^\s*(\w+)\s*$/ ) {
+  if ( $return{'Auth'} =~ /^\s*(\w+)\s*$/ && lc($1) ne 'declined' ) {
 
     $self->is_success(1);
     $self->authorization( $return{'Auth'}   );
 
     $self->is_success(1);
     $self->authorization( $return{'Auth'}   );