aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Christian Hesse <mail@eworm.de>2022-07-05 13:43:50 +0200
committerGravatar Christian Hesse <mail@eworm.de>2022-07-06 11:37:02 +0200
commitf50d155500011e449c42d9389333a91e0d23939b (patch)
tree4796436f3e37cf9a920d545014887303f84ce23f
parenta7c94445454642ce57be4da9693f914da5d05c1a (diff)
netwatch-notify: $NetwatchNotifyHook: rename variable: $Type -> $State
-rw-r--r--netwatch-notify12
1 files changed, 6 insertions, 6 deletions
diff --git a/netwatch-notify b/netwatch-notify
index e3f0633..112cf9e 100644
--- a/netwatch-notify
+++ b/netwatch-notify
@@ -21,9 +21,9 @@
:global SymbolForNotification;
:local NetwatchNotifyHook do={
- :local Name [ :tostr $1 ];
- :local Type [ :tostr $2 ];
- :local Hook [ :tostr $3 ];
+ :local Name [ :tostr $1 ];
+ :local State [ :tostr $2 ];
+ :local Hook [ :tostr $3 ];
:global LogPrintExit2;
:global ValidateSyntax;
@@ -32,15 +32,15 @@
:do {
[ :parse $Hook ];
} on-error={
- $LogPrintExit2 warning $0 ("The " . $Type . "-hook for host " . $Name . " failed to run.") false;
+ $LogPrintExit2 warning $0 ("The " . $State . "-hook for host " . $Name . " failed to run.") false;
:return ("The hook failed to run.");
}
} else={
- $LogPrintExit2 warning $0 ("The " . $Type . "-hook for host " . $Name . " failed syntax validation.") false;
+ $LogPrintExit2 warning $0 ("The " . $State . "-hook for host " . $Name . " failed syntax validation.") false;
:return ("The hook failed syntax validation.");
}
- $LogPrintExit2 info $0 ("Ran hook on host " . $Name . " " . $Type . ": " . $Hook) false;
+ $LogPrintExit2 info $0 ("Ran hook on host " . $Name . " " . $State . ": " . $Hook) false;
:return ("Ran hook:\n" . $Hook);
}