mirror of
https://github.com/eworm-de/routeros-scripts.git
synced 2025-06-21 01:25:52 +02:00
mod/notification-email: use $FileExists ...
... to work around restrictions in new file handling.
This commit is contained in:
parent
daee05dbd7
commit
e3284ca770
1 changed files with 2 additions and 1 deletions
|
@ -40,6 +40,7 @@
|
|||
|
||||
:global EitherOr;
|
||||
:global EMailGenerateFrom;
|
||||
:global FileExists;
|
||||
:global IsDNSResolving;
|
||||
:global IsTimeSync;
|
||||
:global LogPrint;
|
||||
|
@ -93,7 +94,7 @@
|
|||
:onerror Err {
|
||||
:local Attach ({});
|
||||
:foreach File in=[ :toarray [ $EitherOr ($Message->"attach") "" ] ] do={
|
||||
:if ([ :len [ /file/find where name=$File ] ] = 1) do={
|
||||
:if ([ $FileExists $File ] = true) do={
|
||||
:set Attach ($Attach, $File);
|
||||
} else={
|
||||
$LogPrint warning $0 ("File '" . $File . "' does not exist, can not attach.");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue