@@ -3,7 +3,7 @@ |
||
3 | 3 | namespace JeroenDesloovere\Geolocation\tests; |
4 | 4 | |
5 | 5 | // required to load |
6 | -require_once __DIR__ . '/../vendor/autoload.php'; |
|
6 | +require_once __DIR__.'/../vendor/autoload.php'; |
|
7 | 7 | |
8 | 8 | /* |
9 | 9 | * This file is part of the Geolocation PHP Class from Jeroen Desloovere. |
@@ -15,7 +15,7 @@ discard block |
||
15 | 15 | { |
16 | 16 | return new self( |
17 | 17 | 'No address found for coordinates. |
18 | - With latitude: "' . $latitude . '" and longitude "' . $longitude . '".' |
|
18 | + With latitude: "' . $latitude.'" and longitude "'.$longitude.'".' |
|
19 | 19 | ); |
20 | 20 | } |
21 | 21 | |
@@ -23,7 +23,7 @@ discard block |
||
23 | 23 | { |
24 | 24 | return new self( |
25 | 25 | 'No coordinates found for address. |
26 | - With address: "' . implode(', ', $addressData) . '".' |
|
26 | + With address: "' . implode(', ', $addressData).'".' |
|
27 | 27 | ); |
28 | 28 | } |
29 | 29 | } |
@@ -36,18 +36,18 @@ discard block |
||
36 | 36 | private function createUrl(array $parameters): string |
37 | 37 | { |
38 | 38 | // define url |
39 | - $url = ($this->https ? 'https://' : 'http://') . self::API_URL . '?'; |
|
39 | + $url = ($this->https ? 'https://' : 'http://').self::API_URL.'?'; |
|
40 | 40 | |
41 | 41 | // add every parameter to the url |
42 | 42 | foreach ($parameters as $key => $value) { |
43 | - $url .= $key . '=' . urlencode($value) . '&'; |
|
43 | + $url .= $key.'='.urlencode($value).'&'; |
|
44 | 44 | } |
45 | 45 | |
46 | 46 | // trim last & |
47 | 47 | $url = trim($url, '&'); |
48 | 48 | |
49 | 49 | if ($this->api_key) { |
50 | - $url .= '&key=' . $this->api_key; |
|
50 | + $url .= '&key='.$this->api_key; |
|
51 | 51 | } |
52 | 52 | |
53 | 53 | return $url; |
@@ -139,7 +139,7 @@ discard block |
||
139 | 139 | |
140 | 140 | // define result |
141 | 141 | $addressSuggestions = $this->doCall(array( |
142 | - 'latlng' => $latitude . ',' . $longitude, |
|
142 | + 'latlng' => $latitude.','.$longitude, |
|
143 | 143 | 'sensor' => 'false' |
144 | 144 | )); |
145 | 145 | |
@@ -171,7 +171,7 @@ discard block |
||
171 | 171 | ): Coordinates { |
172 | 172 | $items = []; |
173 | 173 | $variables = [$street, $streetNumber, $city, $zip, $country]; |
174 | - for ($i = 0; $i < count($variables); $i ++) { |
|
174 | + for ($i = 0; $i < count($variables); $i++) { |
|
175 | 175 | if (empty($variables[$i])) { |
176 | 176 | continue; |
177 | 177 | } |