*Update dist

This commit is contained in:
Derrick Hammer 2022-07-31 23:11:31 -04:00
parent 681d3f4b9f
commit 03a5933394
2 changed files with 5 additions and 2 deletions

2
dist/util.d.ts.map vendored
View File

@ -1 +1 @@
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../src/util.ts"],"names":[],"mappings":"AAWA,wBAAgB,OAAO,CAAC,MAAM,EAAE,GAAG,EAAE,IAAI,GAAE,GAAQ,GAAG,GAAG,EAAE,CAuC1D"}
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../src/util.ts"],"names":[],"mappings":"AAaA,wBAAgB,OAAO,CAAC,MAAM,EAAE,GAAG,EAAE,IAAI,GAAE,GAAQ,GAAG,GAAG,EAAE,CA0C1D"}

5
dist/util.js vendored
View File

@ -15,7 +15,10 @@ export function flatten(target, opts = {}) {
const output = [];
function step(object, prev, currentDepth) {
currentDepth = currentDepth || 1;
Object.keys(object).forEach(function (key) {
if (!Array.isArray(object)) {
object = Object.keys(object);
}
object.forEach(function (key) {
const value = object[key];
const isarray = opts.safe && Array.isArray(value);
const type = Object.prototype.toString.call(value);