| 1 | <?php |
||
| 7 | abstract class BaseNotification extends Notification |
||
| 8 | { |
||
| 9 | /** |
||
| 10 | * Get the notification's delivery channels. |
||
| 11 | * |
||
| 12 | * @param mixed $notifiable |
||
| 13 | * @return array |
||
| 14 | */ |
||
| 15 | public function via($notifiable) |
||
| 19 | |||
| 20 | public function getMonitorProperties($extraProperties = []): array |
||
| 21 | { |
||
| 22 | $monitor = $this->event->monitor; |
||
| 23 | |||
| 24 | $properties['location'] = config('laravel-uptime-monitor.notifications.location'); |
||
| 25 | |||
| 26 | $properties['url'] = (string) $monitor->url; |
||
| 27 | |||
| 28 | if (! empty($monitor->look_for_string)) { |
||
| 29 | $properties['look for string'] = $monitor->look_for_string; |
||
| 30 | } |
||
| 31 | |||
| 32 | $properties = array_merge($properties, $extraProperties); |
||
| 33 | |||
| 34 | if ($monitor->check_ssl_certificate) { |
||
| 35 | $properties['ssl certificate valid'] = $monitor->ssl_certificate_status; |
||
| 36 | $properties['ssl certificate issuer'] = $monitor->ssl_certificate_issuer; |
||
| 37 | $properties['ssl certificate expiration date'] = $monitor->formattedSslCertificateExpirationDate; |
||
| 38 | } |
||
| 39 | |||
| 40 | return array_filter($properties); |
||
| 41 | } |
||
| 42 | |||
| 43 | public function isStillRelevant(): bool |
||
| 47 | } |
||
| 48 |
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.