Skip to content
Browse files

matchPath() fixed to stop recursion when nextPath is empty

  • Loading branch information...
1 parent 1b53d33 commit 08a6b5a531aa995ed33122129f0a280b3b334401 @scf2k scf2k committed with arikon
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/level.js
View
2 lib/level.js
@@ -652,7 +652,7 @@ var Level = exports.Level = INHERIT(/** @lends Level.prototype */{
res = [match];
- if (bemUtil.isLevel(levelPath)) {
+ if (nextPath && bemUtil.isLevel(levelPath)) {
nextRes = createLevel(levelPath).matchPath(nextPath);
res = nextRes? res.concat(nextRes) : false;
}

0 comments on commit 08a6b5a

Please sign in to comment.
Something went wrong with that request. Please try again.