Added subject to web hook same as used for e-mail.

This commit is contained in:
Thomas Ulsø Kristensen 2022-06-13 08:26:18 +02:00
parent 106a96b087
commit 2c32c4adee
1 changed files with 3 additions and 1 deletions

View File

@ -609,6 +609,7 @@ class StatusNotifier
}
$webhook = psm_build_webhook();
$subject = key_exists('subject', $combi) ? $combi['subject'] : psm_parse_msg($this->status_new, 'email_subject', $this->server);
$message = key_exists('message', $combi) ?
$combi['message'] :
@ -638,7 +639,8 @@ class StatusNotifier
'#server_label' => $this->server['label'],
'#server_error' => $this->server['error'],
'#server_last_offline_duration' => $this->status_new ? $this->server['last_offline_duration'] : '',
'#status' => $this->status_new ? 'online' : 'offline'
'#status' => $this->status_new ? 'online' : 'offline',
'#subject' => $subject
]);
}
}