mirror of
https://github.com/eworm-de/routeros-scripts.git
synced 2024-05-11 05:55:19 +00:00
global-functions: $ParseKeyValueStore: key without value for boolean true
This commit is contained in:
@ -431,8 +431,12 @@
|
||||
}
|
||||
:local Result [ :toarray "" ];
|
||||
:foreach KeyValue in=[ :toarray $Source ] do={
|
||||
:set KeyValue [ :toarray [ $CharacterReplace $KeyValue "=" "," ] ];
|
||||
:set ($Result->($KeyValue->0)) ($KeyValue->1);
|
||||
:if ([ :find $KeyValue "=" ]) do={
|
||||
:set KeyValue [ :toarray [ $CharacterReplace $KeyValue "=" "," ] ];
|
||||
:set ($Result->($KeyValue->0)) ($KeyValue->1);
|
||||
} else={
|
||||
:set ($Result->$KeyValue) true;
|
||||
}
|
||||
}
|
||||
:return $Result;
|
||||
}
|
||||
|
Reference in New Issue
Block a user