mirror of
https://github.com/eworm-de/routeros-scripts.git
synced 2025-08-15 23:37:51 +02:00
sms-action: use $LogAndError
This commit is contained in:
parent
f1ab717ae5
commit
7ec411c542
1 changed files with 3 additions and 2 deletions
|
@ -6,11 +6,12 @@
|
||||||
|
|
||||||
:global SmsAction;
|
:global SmsAction;
|
||||||
|
|
||||||
|
:global LogAndError;
|
||||||
|
|
||||||
:local Action $action;
|
:local Action $action;
|
||||||
|
|
||||||
:if ([ :typeof $Action ] = "nothing") do={
|
:if ([ :typeof $Action ] = "nothing") do={
|
||||||
:log error "This script is supposed to run from SMS hook with action=...";
|
$LogAndError "This script is supposed to run from SMS hook with action=...";
|
||||||
:error "Error: See log for details.";
|
|
||||||
}
|
}
|
||||||
|
|
||||||
:local Code ($SmsAction->$Action);
|
:local Code ($SmsAction->$Action);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue