properties
properties copied to clipboard
properties.path() not working for dot-separated keys after upgrade from 2.1.1 to 2.2.0
Hi, thanks for this library! I'm using it to parse Spring-like properties files.
Given a properties file with no header and a dot-separated value:
testkey.nested=testval
In 2.1.1 I used to be able to do:
const propertiesReader = require("properties-reader");
const properties = propertiesReader("test.properties");
properties.path()
This would give an object: { testkey: { nested: 'testval' } }
In 2.2.0, path() here returns: {}
The keys are there, they just don't show up in console.log() or for (const key of properties.path()) because they aren't enumerable. Added #71 to make them enumerable.