@contrast/flat
Advanced tools
Comparing version 4.1.1 to 4.2.0
10
index.js
@@ -18,2 +18,3 @@ 'use strict'; | ||
const delimiter = opts.delimiter || '.'; | ||
const maxDepth = opts.maxDepth; | ||
const output = {}; | ||
@@ -35,6 +36,7 @@ | ||
!isArray && | ||
!isBuffer && | ||
isObject && | ||
Object.keys(value).length && | ||
!isDomain | ||
!isBuffer && | ||
isObject && | ||
Object.keys(value).length && | ||
!isDomain && | ||
(!opts.maxDepth || currentDepth < maxDepth) | ||
) { | ||
@@ -41,0 +43,0 @@ return step(value, newKey, currentDepth + 1); |
{ | ||
"name": "@contrast/flat", | ||
"version": "4.1.1", | ||
"version": "4.2.0", | ||
"main": "index.js", | ||
"scripts": { | ||
"test": "mocha -u tdd --reporter spec && standard index.js test/index.js" | ||
"test": "mocha -u tdd --reporter spec" | ||
}, | ||
@@ -8,0 +8,0 @@ "license": "BSD-3-Clause", |
4825
4
44