If you put in double slashes in the path part of the PayPal URL and then
PayPal asks you to do their captcha, they have some sort of bug where
they do the wrong redirect after the captcha to https://cgi-bin/webscr.
Issue #153
}
$this->_component = $params['component'];
$token = $this->setExpressCheckOut($params);
+ $siteUrl = rtrim($this->_paymentProcessor['url_site'], '/');
return [
'pre_approval_parameters' => ['token' => $token],
- 'redirect_url' => $this->_paymentProcessor['url_site'] . "/cgi-bin/webscr?cmd=_express-checkout&token=$token",
+ 'redirect_url' => $siteUrl . "/cgi-bin/webscr?cmd=_express-checkout&token=$token",
];
}