We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 33be7b8 commit c7c68deCopy full SHA for c7c68de
src/Client.php
@@ -145,7 +145,10 @@ public function getMerchantPaymentMethods($merchant)
145
146
public function getPaymentMethods($uri, $options = array())
147
{
148
- $this->initCurl($this->_endpoint . '/merchants/');
+ if (!preg_match('!^https?://!', $uri)) {
149
+ $uri = $this->_endpoint . '/orders/' . $uri;
150
+ }
151
+ $this->initCurl($uri . '/payment_methods' . (count($options) > 0 ? '?' . http_build_query($options) : ''));
152
curl_setopt($this->ch, CURLOPT_CUSTOMREQUEST, 'GET');
153
curl_setopt($this->ch, CURLOPT_HTTPHEADER, array('Accept: application/json'));
154
$this->sendRequest();
0 commit comments