Skip to content

Commit 890d726

Browse files
author
Viktor Tymchynskyi
committed
Merge remote-tracking branch 'origin/MAGETWO-50902' into MPI-BUGFIXES
2 parents 8cd0ec7 + d9d0f28 commit 890d726

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

app/code/Magento/Paypal/Controller/Express/AbstractExpress/Start.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ class Start extends GetToken
2121
public function execute()
2222
{
2323
try {
24-
2524
$token = $this->getToken();
2625
if ($token === null) {
2726

app/code/Magento/Paypal/Controller/Express/GetToken.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,9 @@ public function execute()
5353
if ($token === null) {
5454
$token = false;
5555
}
56+
$url = $this->_checkout->getRedirectUrl();
5657
$this->_initToken($token);
57-
$controllerResult->setData(['token' => $token]);
58+
$controllerResult->setData(['url' => $url]);
5859
} catch (LocalizedException $exception) {
5960
$this->messageManager->addExceptionMessage(
6061
$exception,

app/code/Magento/Paypal/view/frontend/web/js/in-context/express-checkout.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ define(
4242
}
4343
).done(
4444
function (response) {
45-
if (response && response.token) {
46-
paypalExpressCheckout.checkout.startFlow(response.token);
45+
if (response && response.url) {
46+
paypalExpressCheckout.checkout.startFlow(response.url);
4747

4848
return;
4949
}

app/code/Magento/Paypal/view/frontend/web/js/view/payment/method-renderer/in-context/checkout-express.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@ define(
5252
}
5353
).done(
5454
function (response) {
55-
if (response && response.token) {
56-
paypalExpressCheckout.checkout.startFlow(response.token);
55+
if (response && response.url) {
56+
paypalExpressCheckout.checkout.startFlow(response.url);
5757

5858
return;
5959
}

0 commit comments

Comments
 (0)