https://www.mediawiki.org/wiki/Special:Code/MediaWiki/102140
Revision: 102140
Author: khorn
Date: 2011-11-06 02:00:47 +0000 (Sun, 06 Nov 2011)
Log Message:
-----------
Prevents anything that isn't a credit card transaction from abusing the
GlobalCollect resultswitcher.
Modified Paths:
--------------
trunk/extensions/DonationInterface/globalcollect_gateway/globalcollect_resultswitcher.body.php
Modified:
trunk/extensions/DonationInterface/globalcollect_gateway/globalcollect_resultswitcher.body.php
===================================================================
---
trunk/extensions/DonationInterface/globalcollect_gateway/globalcollect_resultswitcher.body.php
2011-11-06 01:17:04 UTC (rev 102139)
+++
trunk/extensions/DonationInterface/globalcollect_gateway/globalcollect_resultswitcher.body.php
2011-11-06 02:00:47 UTC (rev 102140)
@@ -62,9 +62,10 @@
if ( $this->adapter->checkTokens() ) {
// Display form for the first time
$oid = $wgRequest->getText( 'order_id' );
- $adapter_oid = $this->adapter->getData_Raw();
- $adapter_oid = $adapter_oid['order_id'];
- if ( $oid && !empty( $oid ) && $oid === $adapter_oid ) {
+ $adapter_oid = $this->adapter->getData_Raw( 'order_id'
);
+
+ //this next block is for credit card coming back from
GC. Only that. Nothing else, ever.
+ if ( $this->adapter->getData_Raw( 'payment_method') ===
'cc' && $oid && !empty( $oid ) && $oid === $adapter_oid ) {
if ( !array_key_exists( 'order_status',
$_SESSION ) || !array_key_exists( $oid, $_SESSION['order_status'] ) ) {
$_SESSION['order_status'][$oid] =
$this->adapter->do_transaction( 'Confirm_CreditCard' );
$_SESSION['order_status'][$oid]['data']['count'] = 0;
_______________________________________________
MediaWiki-CVS mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs