Mwalker has submitted this change and it was merged.
Change subject: set is_recurring and is_refund to false and not null/unset, if
they are known.
......................................................................
set is_recurring and is_refund to false and not null/unset, if they are known.
Change-Id: I7e5228152f7bece8af65942d885e73b541958af9
---
M sites/all/modules/wmf_civicrm/WmfTransaction.php
1 file changed, 3 insertions(+), 3 deletions(-)
Approvals:
Mwalker: Looks good to me, approved
jenkins-bot: Verified
diff --git a/sites/all/modules/wmf_civicrm/WmfTransaction.php
b/sites/all/modules/wmf_civicrm/WmfTransaction.php
index 3fd5c0f..dfc400c 100644
--- a/sites/all/modules/wmf_civicrm/WmfTransaction.php
+++ b/sites/all/modules/wmf_civicrm/WmfTransaction.php
@@ -58,9 +58,7 @@
$transaction = new WmfTransaction();
$transaction->gateway_txn_id = $msg['gateway_txn_id'];
$transaction->gateway = $msg['gateway'];
- if ( array_key_exists( 'recurring', $msg ) && $msg['recurring'] ) {
- $transaction->is_recurring = true;
- }
+ $transaction->is_recurring = ( array_key_exists( 'recurring', $msg )
&& $msg['recurring'] );
return $transaction;
}
@@ -73,11 +71,13 @@
throw new WmfException( 'INVALID_MESSAGE', "Missing ID." );
}
+ $transaction->is_refund = false;
while ( $parts[0] === "RFD" or $parts[0] === "REFUND" ) {
$transaction->is_refund = true;
array_shift( $parts );
}
+ $transaction->is_recurring = false;
while ( $parts[0] === "RECURRING" ) {
$transaction->is_recurring = true;
array_shift( $parts );
--
To view, visit https://gerrit.wikimedia.org/r/114910
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I7e5228152f7bece8af65942d885e73b541958af9
Gerrit-PatchSet: 1
Gerrit-Project: wikimedia/fundraising/crm
Gerrit-Branch: master
Gerrit-Owner: Adamw <[email protected]>
Gerrit-Reviewer: Katie Horn <[email protected]>
Gerrit-Reviewer: Mwalker <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits