jenkins-bot has submitted this change and it was merged.
Change subject: Fix name of staged variable risk_score
......................................................................
Fix name of staged variable risk_score
Needs to be rounded off before being sent as 'offset'.
Bug: T114958
Change-Id: I50484f459d1717982a2873b3be5d096611cb3f87
---
M adyen_gateway/adyen.adapter.php
M tests/Adapter/Adyen/AdyenTest.php
2 files changed, 6 insertions(+), 4 deletions(-)
Approvals:
Awight: Looks good to me, approved
jenkins-bot: Verified
diff --git a/adyen_gateway/adyen.adapter.php b/adyen_gateway/adyen.adapter.php
index 672fc62..d70d377 100644
--- a/adyen_gateway/adyen.adapter.php
+++ b/adyen_gateway/adyen.adapter.php
@@ -54,7 +54,7 @@
'zip',
'billing_signature',
'hpp_signature',
- 'fraud_score',
+ 'risk_score',
);
}
@@ -521,9 +521,11 @@
protected function stage_risk_score() {
//This isn't smart enough to grab a new value here;
//Late-arriving values have to trigger a restage via addData or
- //this will always equil the risk_score at the time of object
+ //this will always equal the risk_score at the time of object
//construction. Still need the formatting, though.
- $this->staged_data['risk_score'] = ( string ) round(
$this->unstaged_data['risk_score'] );
+ if ( isset( $this->unstaged_data['risk_score'] ) ) {
+ $this->staged_data['risk_score'] = ( string ) round(
$this->unstaged_data['risk_score'] );
+ }
}
protected function stage_hpp_signature() {
diff --git a/tests/Adapter/Adyen/AdyenTest.php
b/tests/Adapter/Adyen/AdyenTest.php
index 5e0c2a8..cc6f928 100644
--- a/tests/Adapter/Adyen/AdyenTest.php
+++ b/tests/Adapter/Adyen/AdyenTest.php
@@ -71,7 +71,7 @@
'skinCode' => 'testskin',
'shopperLocale' => 'en',
'shopperEmail' => '[email protected]',
- 'offset' => 51.5, //once we construct the
FraudFiltersTestCase, it should land here.
+ 'offset' => '52', //once we construct the
FraudFiltersTestCase, it should land here.
);
//deal with problem keys.
--
To view, visit https://gerrit.wikimedia.org/r/248382
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I50484f459d1717982a2873b3be5d096611cb3f87
Gerrit-PatchSet: 3
Gerrit-Project: mediawiki/extensions/DonationInterface
Gerrit-Branch: master
Gerrit-Owner: Ejegg <[email protected]>
Gerrit-Reviewer: AndyRussG <[email protected]>
Gerrit-Reviewer: Awight <[email protected]>
Gerrit-Reviewer: Cdentinger <[email protected]>
Gerrit-Reviewer: Ssmith <[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