fix paymask removal when editing a customer with a tokenized card, RT#74900
[freeside.git] / httemplate / edit / process / cust_main.cgi
index 4b89939..a86819f 100755 (executable)
@@ -330,6 +330,7 @@ if ( $new->custnum eq '' or $duplicate_of ) {
      )
   {
     $new->payinfo($old->payinfo);
+    $new->paymask($old->paymask) if ! $new->paymask || $new->paymask =~ /^N\/A/;
 
   } elsif ( $new->payby =~ /^(CHEK|DCHK)$/ && $new->payinfo =~ /xx/ ) {
     #fix for #3085 "edit of customer's routing code only surprisingly causes