| Conditions | 3 |
| Paths | 4 |
| Total Lines | 21 |
| Code Lines | 11 |
| Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | <?php |
||
| 20 | public function getSiteProperties($extraProperties): array |
||
| 21 | { |
||
| 22 | $site = $this->event->site; |
||
| 23 | |||
| 24 | $properties['location'] = config('laravel-uptime-monitor.location'); |
||
| 25 | |||
| 26 | $properties['url'] = (string) $site->url; |
||
| 27 | |||
| 28 | if (! empty($site->look_for_string)) { |
||
| 29 | $properties['look for string'] = $site->look_for_string; |
||
| 30 | } |
||
| 31 | |||
| 32 | $properties = array_merge($properties, $extraProperties); |
||
| 33 | |||
| 34 | if ($site->check_ssl_certificate) { |
||
| 35 | $properties['ssl certificate valid'] = $site->ssl_certificate_status; |
||
| 36 | $properties['ssl certificate issuer'] = $site->ssl_certificate_issuer; |
||
| 37 | $properties['ssl certificate expiration date'] = $site->formattedSslCertificateExpirationDate; |
||
| 38 | } |
||
| 39 | |||
| 40 | return array_filter($properties); |
||
| 41 | } |
||
| 48 |
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.