[MediaWiki-commits] [Gerrit] Shut up a warning, remove test code from prod - change (mediawiki...DonationInterface)
jenkins-bot has submitted this change and it was merged. Change subject: Shut up a warning, remove test code from prod .. Shut up a warning, remove test code from prod There's no reason to check for test, given that testform is only consulted in ( data.result.formaction || data.result.testform ), to run some code that depends on formaction being set Change-Id: I22ca7ce1f6560186e7c0934769fe8df822a178bb --- M gateway_common/donation.api.php M globalcollect_gateway/forms/js/gc.js 2 files changed, 1 insertion(+), 4 deletions(-) Approvals: Awight: Looks good to me, approved jenkins-bot: Verified diff --git a/gateway_common/donation.api.php b/gateway_common/donation.api.php index add7494..8daf499 100644 --- a/gateway_common/donation.api.php +++ b/gateway_common/donation.api.php @@ -64,9 +64,6 @@ if ( array_key_exists( 'gateway_params', $data ) ) { $outputResult['gateway_params'] = $data['gateway_params']; } - if ( $gatewayObj->getMerchantID() === 'test' ) { - $outputResult['testform'] = true; - } if ( array_key_exists( 'RESPMSG', $data ) ) { $outputResult['responsemsg'] = $data['RESPMSG']; } diff --git a/globalcollect_gateway/forms/js/gc.js b/globalcollect_gateway/forms/js/gc.js index 608ae5c..94a3c16 100644 --- a/globalcollect_gateway/forms/js/gc.js +++ b/globalcollect_gateway/forms/js/gc.js @@ -80,7 +80,7 @@ $( '#payment' ).empty(); // Hide spinner mediaWiki.donationInterface.validation.showErrors( data.result.errors ); $( '#paymentContinue' ).show(); // Show continue button in 2nd section - } else if ( data.result.formaction || data.result.testform ) { + } else if ( data.result.formaction ) { mediaWiki.generatePaymentForm( data ); } } -- To view, visit https://gerrit.wikimedia.org/r/293453 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I22ca7ce1f6560186e7c0934769fe8df822a178bb Gerrit-PatchSet: 2 Gerrit-Project: mediawiki/extensions/DonationInterface Gerrit-Branch: master Gerrit-Owner: EjeggGerrit-Reviewer: AndyRussG Gerrit-Reviewer: Awight Gerrit-Reviewer: Cdentinger Gerrit-Reviewer: Ssmith Gerrit-Reviewer: XenoRyet Gerrit-Reviewer: jenkins-bot <> ___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits
[MediaWiki-commits] [Gerrit] Shut up a warning, remove test code from prod - change (mediawiki...DonationInterface)
Ejegg has uploaded a new change for review. https://gerrit.wikimedia.org/r/293453 Change subject: Shut up a warning, remove test code from prod .. Shut up a warning, remove test code from prod There's no reason to check for test, given that testform is only consulted in ( data.result.formaction || data.result.testform ), to run some code that depends on formaction being set Change-Id: I22ca7ce1f6560186e7c0934769fe8df822a178bb --- M gateway_common/donation.api.php M globalcollect_gateway/forms/js/gc.js 2 files changed, 1 insertion(+), 4 deletions(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/extensions/DonationInterface refs/changes/53/293453/1 diff --git a/gateway_common/donation.api.php b/gateway_common/donation.api.php index add7494..8daf499 100644 --- a/gateway_common/donation.api.php +++ b/gateway_common/donation.api.php @@ -64,9 +64,6 @@ if ( array_key_exists( 'gateway_params', $data ) ) { $outputResult['gateway_params'] = $data['gateway_params']; } - if ( $gatewayObj->getMerchantID() === 'test' ) { - $outputResult['testform'] = true; - } if ( array_key_exists( 'RESPMSG', $data ) ) { $outputResult['responsemsg'] = $data['RESPMSG']; } diff --git a/globalcollect_gateway/forms/js/gc.js b/globalcollect_gateway/forms/js/gc.js index 608ae5c..94a3c16 100644 --- a/globalcollect_gateway/forms/js/gc.js +++ b/globalcollect_gateway/forms/js/gc.js @@ -80,7 +80,7 @@ $( '#payment' ).empty(); // Hide spinner mediaWiki.donationInterface.validation.showErrors( data.result.errors ); $( '#paymentContinue' ).show(); // Show continue button in 2nd section - } else if ( data.result.formaction || data.result.testform ) { + } else if ( data.result.formaction ) { mediaWiki.generatePaymentForm( data ); } } -- To view, visit https://gerrit.wikimedia.org/r/293453 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I22ca7ce1f6560186e7c0934769fe8df822a178bb Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/extensions/DonationInterface Gerrit-Branch: master Gerrit-Owner: Ejegg___ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits