Remove NEON value in included config

about a month ago

slavaCz
Member | 2
+
0
-

Hi,

I have a NEON parent config and several sub-configs that are being loaded based on detected client. However, I need to remove one specific config value from sub-config. How to acheive that? I know I can force overwriting the array in sub-config, but that's not what I am looking for so I can easily add more items to the parent config in the future.

Example (the reality is a bit more complex):

-- parent.neon --
boo:
… bar: abc
… baz: efg
… etc.

-- client-XYZ.neon --
boo:
… baz # Need to remove this one and keep all other options from parent

about a month ago

CZechBoY
Member | 3349
+
0
-

Cannot you pass NULL as value?

about a month ago

slavaCz
Member | 2
+
0
-

CZechBoY wrote:

Cannot you pass NULL as value?

You can, as a workaround, sort of. But the key still remains there, albeit with null value. Therefore you have to detect, if the value is null everywhere. Functions like \array_keys() will include it as well. I'd like to get rid of it completely, if possible.