Skip to content

Commit

Permalink
Add support for future changes in unified
Browse files Browse the repository at this point in the history
  • Loading branch information
wooorm committed Sep 18, 2015
1 parent 0b6c35b commit fab6a89
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,8 @@ function gatherReferences(file, project) {
var cache = {};
var filePath = file.filePath();
var directory = file.directory;
var ast = file.namespace('mdast').ast;
var space = file.namespace('mdast');
var ast = space.tree || space.ast;
var getDefinition;
var prefix = '';

Expand Down Expand Up @@ -300,7 +301,8 @@ function gatherExposedFactory() {
*/
function gather(file) {
var filePath = file.filePath();
var ast = file.namespace('mdast').ast;
var space = file.namespace('mdast');
var ast = space.tree || space.ast;

/*
* Ignore files without AST or filename.
Expand Down

0 comments on commit fab6a89

Please sign in to comment.