You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I customized my email subject to the following: [{{STATUS}}] {{NAME}} - {{HOSTNAME_OR_URL}}
However, because "Group" monitor types don't have a hostname or URL, the value is Null. That's fine of course, but it appears literally as "null" when used in the email subject, e.g.:
[β Up] Main Web Server - null
So the bug is that the {{HOSTNAME_OR_URL}} should be handled properly for monitor types that don't have a hostname/URL (Group and maybe others). Also, perhaps instead of just using an empty string, use "n/a"? For my template above, for example, if it were blank it would show up as:
[β Up] Main Web Server -
but instead maybe this is better?
[β Up] Main Web Server - n/a
I'm not sure :)
π Reproduction steps
Setup an email notification and customize the email subject to utilize {{HOSTNAME_OR_URL}}
Create a Group monitor and turn on the Email notification for it
Add another regular monitor to it
Trigger an email (make the monitor UP/DOWN)
π Expected behavior
null does not show in the email subject.
π Actual Behavior
The literal string "null" shows.
π» Uptime-Kuma Version
1.23.16
π» Operating System and Arch
Debian
π Browser
n/a
π₯οΈ Deployment Environment
n/a
π Relevant log output
The text was updated successfully, but these errors were encountered:
π I have found these related issues/pull requests
n/a
π‘οΈ Security Policy
Description
I customized my email subject to the following:
[{{STATUS}}] {{NAME}} - {{HOSTNAME_OR_URL}}
However, because "Group" monitor types don't have a hostname or URL, the value is Null. That's fine of course, but it appears literally as "null" when used in the email subject, e.g.:
[β Up] Main Web Server - null
So the bug is that the {{HOSTNAME_OR_URL}} should be handled properly for monitor types that don't have a hostname/URL (Group and maybe others). Also, perhaps instead of just using an empty string, use "n/a"? For my template above, for example, if it were blank it would show up as:
[β Up] Main Web Server -
but instead maybe this is better?
[β Up] Main Web Server - n/a
I'm not sure :)
π Reproduction steps
π Expected behavior
null does not show in the email subject.
π Actual Behavior
The literal string "null" shows.
π» Uptime-Kuma Version
1.23.16
π» Operating System and Arch
Debian
π Browser
n/a
π₯οΈ Deployment Environment
n/a
π Relevant log output
The text was updated successfully, but these errors were encountered: