From 855399b2bc888e592a2a440425fd07430b18f24b Mon Sep 17 00:00:00 2001 From: Christian Hesse Date: Thu, 24 Jun 2021 16:48:49 +0200 Subject: global-functions: $RandomDelay: allow to specify unit in second argument --- global-functions | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) 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 -- cgit v1.2.3-70-g09d2