Skip to content

Commit

Permalink
fix(TokenTree): Recursive construction for extended TokenTree
Browse files Browse the repository at this point in the history
  • Loading branch information
HHogg committed Dec 7, 2018
1 parent 3e25336 commit 75848a4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/TokenTree.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ export default class TokenTree {
} else if (isCloseToken(ts[this.i])) {
return collection;
} else if (isInlineToken(ts[this.i])) {
new TokenTree(ts[this.i].children, this.options, this.rOptions)
new this.constructor(ts[this.i].children, this.options, this.rOptions)
.forEach((token) => collection.push(token));
} else {
collection.push(this.buildToken(ts[this.i]));
Expand Down

0 comments on commit 75848a4

Please sign in to comment.