aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--global-functions.rsc7
1 files changed, 6 insertions, 1 deletions
diff --git a/global-functions.rsc b/global-functions.rsc
index 25c248d..abb9e22 100644
--- a/global-functions.rsc
+++ b/global-functions.rsc
@@ -931,6 +931,11 @@
:local Script [ :tostr $1 ];
:global LogPrint;
+ :global ScriptLock;
+
+ :if ([ $ScriptLock $Script ] = false) do={
+ :return false;
+ }
:foreach Job in=[ /system/script/job/find where script=$Script ] do={
:set Job [ /system/script/job/get $Job ];
@@ -942,8 +947,8 @@
:return true;
}
}
- $LogPrint debug $0 ("Script " . $Script . " NOT started from terminal.");
+ $LogPrint debug $0 ("Script " . $Script . " NOT started from terminal.");
:return false;
}