@@ -21,15 +21,15 @@ |
||
21 | 21 | |
22 | 22 | |
23 | 23 | /** |
24 | - * __construct function. |
|
25 | - * |
|
26 | - * Instantiates the main class. |
|
27 | - * Creates a client which is passed to the request construct. |
|
28 | - * |
|
29 | - * @auth_string string Authentication string for QuickPay |
|
30 | - * |
|
31 | - * @access public |
|
32 | - */ |
|
24 | + * __construct function. |
|
25 | + * |
|
26 | + * Instantiates the main class. |
|
27 | + * Creates a client which is passed to the request construct. |
|
28 | + * |
|
29 | + * @auth_string string Authentication string for QuickPay |
|
30 | + * |
|
31 | + * @access public |
|
32 | + */ |
|
33 | 33 | public function __construct($auth_string = '') |
34 | 34 | { |
35 | 35 | $client = new Client($auth_string); |
@@ -77,7 +77,7 @@ |
||
77 | 77 | ); |
78 | 78 | |
79 | 79 | if (!empty($this->auth_string)) { |
80 | - $headers[] = 'Authorization: Basic ' . base64_encode($this->auth_string); |
|
80 | + $headers[] = 'Authorization: Basic '.base64_encode($this->auth_string); |
|
81 | 81 | } |
82 | 82 | |
83 | 83 | $options = array( |
@@ -48,9 +48,9 @@ discard block |
||
48 | 48 | // Add query parameters to $path? |
49 | 49 | if (!empty($query)) { |
50 | 50 | if (strpos($path, '?') === false) { |
51 | - $path .= '?' . http_build_query($query, '', '&'); |
|
51 | + $path .= '?'.http_build_query($query, '', '&'); |
|
52 | 52 | } else { |
53 | - $path .= ini_get('arg_separator.output') . http_build_query($query, '', '&'); |
|
53 | + $path .= ini_get('arg_separator.output').http_build_query($query, '', '&'); |
|
54 | 54 | } |
55 | 55 | } |
56 | 56 | |
@@ -139,7 +139,7 @@ discard block |
||
139 | 139 | */ |
140 | 140 | protected function set_url($params) |
141 | 141 | { |
142 | - curl_setopt($this->client->ch, CURLOPT_URL, Constants::API_URL . trim($params, '/')); |
|
142 | + curl_setopt($this->client->ch, CURLOPT_URL, Constants::API_URL.trim($params, '/')); |
|
143 | 143 | } |
144 | 144 | |
145 | 145 | /** |
@@ -158,7 +158,7 @@ discard block |
||
158 | 158 | curl_setopt($this->client->ch, CURLOPT_CUSTOMREQUEST, $request_type); |
159 | 159 | |
160 | 160 | // If additional data is delivered, we will send it along with the API request |
161 | - if (is_array($form) && ! empty($form)) { |
|
161 | + if (is_array($form) && !empty($form)) { |
|
162 | 162 | curl_setopt($this->client->ch, CURLOPT_POSTFIELDS, http_build_query($form, '', '&')); |
163 | 163 | } |
164 | 164 |