diff --git a/src/dot-object.js b/src/dot-object.js index 6a3a0e5..b1a7135 100644 --- a/src/dot-object.js +++ b/src/dot-object.js @@ -49,6 +49,9 @@ var blacklist = ['__proto__', 'prototype', 'constructor'] var blacklistFilter = function (part) { return blacklist.indexOf(part) === -1 } function parsePath (path, sep) { + if (!path) { + return []; + } if (path.indexOf('[') >= 0) { path = path.replace(/\[/g, '.').replace(/]/g, '') }