Skip to content

Commit 7136dd7

Browse files
authored
fix(notification): check for monitorJSON in Stackfield provider (#7248)
1 parent a5f30d4 commit 7136dd7

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

server/notification-providers/stackfield.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,8 @@ class Stackfield extends NotificationProvider {
2525

2626
const baseURL = await Settings.get("primaryBaseURL");
2727
if (baseURL) {
28-
textMsg += `\n${baseURL + getMonitorRelativeURL(monitorJSON.id)}`;
28+
const urlPath = monitorJSON ? getMonitorRelativeURL(monitorJSON.id) : "/";
29+
textMsg += `\n${baseURL + urlPath}`;
2930
}
3031

3132
const data = {

0 commit comments

Comments
 (0)