fix weird path context state by clearing the context before we visit it

This commit is contained in:
Sebastian McKenzie
2015-04-30 17:19:27 +01:00
parent 062175586c
commit 1066a42fb2
6 changed files with 19 additions and 20 deletions

View File

@@ -34,6 +34,8 @@ export default class TraversalContext {
if (visited.indexOf(path.node) >= 0) continue;
visited.push(path.node);
path.setContext(this.parentPath, this, path.key);
if (path.visit()) {
stop = true;
break;