mirror of
https://git.eworm.de/cgit/routeros-scripts
synced 2025-06-24 18:48:37 +02:00
global-functions: $LogAndError: add severity
This commit is contained in:
parent
6ef764c7d7
commit
3ebf68a08c
12 changed files with 16 additions and 15 deletions
|
@ -492,8 +492,9 @@
|
|||
|
||||
# log and error with same text
|
||||
:set LogAndError do={
|
||||
:local Message [ :tostr $1 ];
|
||||
:local Severity [ :tostr $1 ];
|
||||
:local Message [ :tostr $2 ];
|
||||
|
||||
:log warn $Message;
|
||||
:error $Message;
|
||||
[ :parse (":log " . $Severity . " \$Message") ];
|
||||
:error ($Severity . ": " . $Message);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue