diff options
author | ivan <ivan> | 2007-07-11 06:44:04 +0000 |
---|---|---|
committer | ivan <ivan> | 2007-07-11 06:44:04 +0000 |
commit | e4f4e9e92f7620ee23f2c7347104c56dd93ff704 (patch) | |
tree | d73b4b6884d4a7a7792dfa1a6bafa737ed294fbf /LinkPoint.pm | |
parent | b679c2dd4d58222cbd5363999ced5ef021608728 (diff) |
Trim all non-numeric characters from phone numbers when doing an ACH transaction, as per undocumented suggestion from LinkPoint.
Diffstat (limited to 'LinkPoint.pm')
-rw-r--r-- | LinkPoint.pm | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/LinkPoint.pm b/LinkPoint.pm index 70b6253..6bf9a83 100644 --- a/LinkPoint.pm +++ b/LinkPoint.pm @@ -6,7 +6,8 @@ use Carp qw(croak); use Business::OnlinePayment; @ISA = qw(Business::OnlinePayment); -$VERSION = '0.08'; +$VERSION = '0.09_01'; +$VERSION = eval $VERSION; # modperlstyle: convert the string into a number $DEBUG = 0; use lpperl; #3; #lpperl.pm from LinkPoint @@ -139,6 +140,14 @@ sub submit { if ($self->transaction_type() =~ /^e?check$/i && $content{'action'} =~ /^VOID$/); + #strip phone numbers of non-digits for ACH/echeck + #as per undocumented suggestion from LinkPoint + if ( $self->transaction_type =~ /^e?check$/i ) { + foreach my $field (qw( phone fax )) { + $content{$field} =~ s/\D//g; + } + } + $self->revmap_fields( host => \( $self->server ), port => \( $self->port ), |