| Conditions | 1 |
| Paths | 1 |
| Total Lines | 10 |
| Code Lines | 8 |
| Lines | 0 |
| Ratio | 0 % |
| Tests | 8 |
| CRAP Score | 1 |
| Changes | 0 | ||
| 1 | <?php |
||
| 49 | 5 | public function makeGeolocation($item) |
|
| 50 | { |
||
| 51 | 5 | return collect([ |
|
| 52 | 5 | config('firewall.notifications.message.geolocation.field_latitude') => $item['geoIp']['latitude'], |
|
| 53 | 5 | config('firewall.notifications.message.geolocation.field_longitude') => $item['geoIp']['longitude'], |
|
| 54 | 5 | config('firewall.notifications.message.geolocation.field_country_code') => $item['geoIp']['country_code'], |
|
| 55 | 5 | config('firewall.notifications.message.geolocation.field_country_name') => $item['geoIp']['country_name'], |
|
| 56 | 5 | config('firewall.notifications.message.geolocation.field_city') => $item['geoIp']['city'], |
|
| 57 | 5 | ])->filter()->toArray(); |
|
| 58 | } |
||
| 59 | } |
||
| 60 |