r86686 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r86685‎ | r86686 | r86687 >
Date:00:41, 22 April 2011
Author:awjrichards
Status:deferred
Tags:
Comment:
Dividing formatted amount by 100 as PayPal returns amounts * 100 - thanks for not documenting that, PayPal >_<
Modified paths:
  • /civicrm/trunk/sites/all/modules/paypal_audit/paypal_audit.module (modified) (history)

Diff [purge]

Index: civicrm/trunk/sites/all/modules/paypal_audit/paypal_audit.module
@@ -213,7 +213,7 @@
214214 $formatted_trxn['gateway'] = strtolower( $gateway );
215215 $formatted_trxn['gateway_txn_id'] = ( $gateway == 'PayflowPro' ) ? $trxn[ $columns[ 'Transaction ID' ]] : $trxn[ $columns[ 'PayPal Transaction ID']];
216216 $formatted_trxn['original_currency'] = $trxn[ $columns[ 'Currency Symbol' ]];
217 - $formatted_trxn['gross'] = $trxn[ $columns[ 'Amount' ]];
 217+ $formatted_trxn['gross'] = $trxn[ $columns[ 'Amount' ]]/100;
218218 $formatted_trxn['date'] = strtotime( $trxn[ $columns[ 'Time' ]] );
219219
220220 array_push( $trxns_formatted, $formatted_trxn );

Status & tagging log