mod/notification-email: clean name for display name

This commit is contained in:
Christian Hesse 2024-03-12 22:03:04 +01:00
parent c016a6ef47
commit ccfbabde5e

View file

@ -22,13 +22,15 @@
:set EMailGenerateFrom do={
:global Identity;
:global CleanName;
:local From [ /tool/e-mail/get from ];
:if ($From ~ "<.*>\$") do={
:return $From;
}
:return ("\"" . $Identity . " via routeros-scripts\" <" . $From . ">");
:return ([ $CleanName $Identity ] . " via routeros-scripts <" . $From . ">");
}
# flush e-mail queue