Index: uc_moneris.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/uc_moneris/uc_moneris.module,v
retrieving revision 1.9
diff -u -p -r1.9 uc_moneris.module
--- uc_moneris.module	12 Jan 2010 22:28:18 -0000	1.9
+++ uc_moneris.module	16 Dec 2010 03:43:33 -0000
@@ -369,6 +369,8 @@ function uc_moneris_charge($order_id, $a
     $mpiRequest = new MpiRequest($mpiTxn);
     $mpiHttpPost  = new MpiHttpsPost($store_id, $api_token, $mpiRequest);
     $mpiResponse=$mpiHttpPost->getMpiResponse();
+    
+    dpm($mpiResponse);
 
     $response_values = array(
       '!code'     => $mpiResponse->getMpiSuccess(),
@@ -507,7 +509,7 @@ function uc_moneris_charge($order_id, $a
       }
     }
 
-    if (($this_trans_type == uc_moneris_preauth_string() && $txn_type == uc_moneris_transaction_type()) && intval($response_code) < 49 || $completed == 'true') {
+    if (($this_trans_type == uc_moneris_preauth_string() && $txn_type == uc_moneris_transaction_type()) && (intval($response_code) < 49 || $completed == 'true')) {
       //The previous transaction was a preauth before a capture. Run the transaction again in Capture mode.
       $txnArray = array(
         'type'        =>  variable_get('uc_moneris_api_version', '') .'completion',
