[ic] Verifone IPCharge

Richard Siddall richard.siddall at elirion.net
Fri Mar 20 19:43:39 UTC 2009

Bill Carr wrote:
> On Mar 18, 2009, at 9:53 AM, Mike Heins wrote:
>>  Route  ipcharge   extra   "merchantkey client_id"
> Thanks for the help. Here is a patch. This is working for me. I have  
> also included a 'results_extra' option for getting options back from  
> the payment processor.
> -  my %options = map  { $_=>1 }
> +    my %options = map { $_ => charge_param($_) }
>                   grep { !$ignore{$_} } (
>                                           keys(%$opt),
>                                           map { s/^MV_PAYMENT_//;  

I realized my last e-mail didn't really make a case for not applying 
Bill's patch, and I almost finished a longer explanation when I noticed 
the change above.

I think Bill has actually fixed a bug in 
Vend::Payment::BusinessOnlinePayment, but that his patch as it stands 
duplicates what would be existing functionality if it wasn't for the bug.

I think the keys(%$opt) in the code above is meant to pass route 
parameters to the Business::OnlinePayment constructor as a hash, 
allowing you to do:

	Route ipcharge merchantkey foo
	Route ipcharge client_id bar

but the bug that the delta above fixes means that 
Business::OnlinePayment only gets

	merchantkey => 1, client_id => 1

instead of

	merchantkey => 'foo', client_id => 'bar'

The rest of the patch just allows you to do

	Route ipcharge extra "merchantkey foo"

which doesn't buy you anything.

I'm only addressing the first part of the patch here.

Of course, I might be missing something and misunderstanding what's 
going on.

I think the problem we're actually facing is a lack of examples for how 
to use Vend::Payment::BusinessOnlinePayment.


	Richard Siddall

More information about the interchange-users mailing list