diff options
author | Christian Hesse <mail@eworm.de> | 2021-06-24 16:48:49 +0200 |
---|---|---|
committer | Christian Hesse <mail@eworm.de> | 2021-06-24 22:28:08 +0200 |
commit | 855399b2bc888e592a2a440425fd07430b18f24b (patch) | |
tree | f91c7b6f038fed8b554b20a477b980cc04eca77c /global-functions | |
parent | 39b7bddf497b26a56c20b2dd5722776be11a35ec (diff) |
global-functions: $RandomDelay: allow to specify unit in second argument
Diffstat (limited to 'global-functions')
-rw-r--r-- | global-functions | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/global-functions b/global-functions index 677cfc7..da718f3 100644 --- a/global-functions +++ b/global-functions @@ -658,9 +658,10 @@ # delay a random amount of seconds :set RandomDelay do={ + :global EitherOr; :global GetRandomNumber; - :delay ([ $GetRandomNumber $1 ] . "s"); + :delay ([ $GetRandomNumber $1 ] . [ $EitherOr $2 "s" ]); } # check for required RouterOS version |