jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/355462 )

Change subject: Allow old 'currency_code' param for form chooser
......................................................................


Allow old 'currency_code' param for form chooser

Revert when all incoming links are fixed.

Change-Id: I5d954c75135ba5a51ca4b7630f6b314c0cb866d9
---
M special/GatewayFormChooser.php
1 file changed, 12 insertions(+), 0 deletions(-)

Approvals:
  XenoRyet: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/special/GatewayFormChooser.php b/special/GatewayFormChooser.php
index 3fb21ad..84159f8 100644
--- a/special/GatewayFormChooser.php
+++ b/special/GatewayFormChooser.php
@@ -49,6 +49,10 @@
 
                $country = $getValOrNull( 'country' );
                $currency = $getValOrNull( 'currency' );
+               // TODO: remove when incoming links are updated
+               if ( !$currency ) {
+                       $currency = $getValOrNull( 'currency_code' );
+               }
                $paymentMethod = $getValOrNull( 'payment_method' );
                $paymentSubMethod = $getValOrNull( 'payment_submethod' );
                $gateway = $getValOrNull( 'gateway' );
@@ -92,6 +96,14 @@
                        }
                }
 
+               // TODO: remove when incoming links are updated
+               if ( !empty( $params['currency_code'] ) ) {
+                       if ( empty( $params['currency'] ) ) {
+                               $params['currency'] = $params['currency_code'];
+                       }
+                       unset( $params['currency_code'] );
+               }
+
                $redirectURL = self::buildPaymentsFormURL( $form, $params );
 
                // Perform the redirection

-- 
To view, visit https://gerrit.wikimedia.org/r/355462
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I5d954c75135ba5a51ca4b7630f6b314c0cb866d9
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/extensions/DonationInterface
Gerrit-Branch: master
Gerrit-Owner: Ejegg <[email protected]>
Gerrit-Reviewer: XenoRyet <[email protected]>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to