| Conditions | 2 |
| Paths | 2 |
| Total Lines | 10 |
| Code Lines | 5 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 5 |
| CRAP Score | 2 |
| Changes | 0 | ||
| 1 | <?php |
||
| 75 | 7 | private function generateRequestUrl($address, $region = '', $outputFormat = 'json', $sensor = false) |
|
| 76 | { |
||
| 77 | 7 | $baseUrl = self::API_URL.'/'.$outputFormat.'?address='.urlencode($address).'&sensor='.$sensor; |
|
| 78 | |||
| 79 | 7 | if (!empty($region)) { |
|
| 80 | 1 | $baseUrl .= "®ion={$region}"; |
|
| 81 | } |
||
| 82 | |||
| 83 | 7 | return $baseUrl; |
|
| 84 | } |
||
| 85 | } |
||
| 86 |