better fix for using new payment duplicate stuff with cc encryption :)
authorivan <ivan>
Mon, 5 May 2008 01:52:58 +0000 (01:52 +0000)
committerivan <ivan>
Mon, 5 May 2008 01:52:58 +0000 (01:52 +0000)
FS/FS/payinfo_Mixin.pm

index 40b97a9..f2edbd2 100644 (file)
@@ -230,8 +230,14 @@ sub payinfo_check {
       $self->payinfo('N/A'); #???
     }
   } else {
-    my $error = $self->ut_textn('payinfo');
-    return $error if $error;
+    if ( $self->is_encrypted($self->payinfo) ) {
+      #something better?  all it would cause is a decryption error anyway?
+      my $error = $self->ut_anythingn('payinfo');
+      return $error if $error;
+    } else {
+      my $error = $self->ut_textn('payinfo');
+      return $error if $error;
+    }
   }
 }