1
0
mirror of https://github.com/eworm-de/routeros-scripts.git synced 2024-05-11 05:55:19 +00:00

global-functions: $AlignRight: use $CharacterMultiply

This commit is contained in:
Christian Hesse
2023-12-04 10:58:27 +01:00
parent 8f24b4c490
commit 5e2e65b252

View File

@@ -81,10 +81,11 @@
:local Input [ :tostr $1 ];
:local Len [ :tonum $2 ];
:global CharacterMultiply;
:global EitherOr;
:local Spaces " ";
:set Len [ $EitherOr $Len 8 ];
:local Spaces [ $CharacterMultiply " " $Len ];
:return ([ :pick $Spaces 0 ($Len - [ :len $Input ]) ] . $Input);
}