mirror of
https://git.eworm.de/cgit/routeros-scripts
synced 2025-06-25 02:58:37 +02:00
global-functions: $ParseKeyValueStore: key without value for boolean true
This commit is contained in:
parent
5b03ae4fa2
commit
2aaea7c58e
1 changed files with 6 additions and 2 deletions
|
@ -431,8 +431,12 @@
|
||||||
}
|
}
|
||||||
:local Result [ :toarray "" ];
|
:local Result [ :toarray "" ];
|
||||||
:foreach KeyValue in=[ :toarray $Source ] do={
|
:foreach KeyValue in=[ :toarray $Source ] do={
|
||||||
:set KeyValue [ :toarray [ $CharacterReplace $KeyValue "=" "," ] ];
|
:if ([ :find $KeyValue "=" ]) do={
|
||||||
:set ($Result->($KeyValue->0)) ($KeyValue->1);
|
:set KeyValue [ :toarray [ $CharacterReplace $KeyValue "=" "," ] ];
|
||||||
|
:set ($Result->($KeyValue->0)) ($KeyValue->1);
|
||||||
|
} else={
|
||||||
|
:set ($Result->$KeyValue) true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
:return $Result;
|
:return $Result;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue