Skip to content

Commit b10f84c

Browse files
authored
Merge pull request #31 from coderaiser/patch-1
Error: You must pass a scope and parentPath unless traversing a Program/File. Instead of that you tried to traverse a undefined node without passing scope and parentPath.
2 parents 439ef85 + cc6ca5e commit b10f84c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ module.exports = function index(
1111
options: Options
1212
): string | null | undefined | void {
1313
const ast = options.noRecastWorkaround
14-
? api.jscodeshift(fileInfo.source).get()
14+
? api.jscodeshift(fileInfo.source).get().value
1515
: recast.parse(fileInfo.source, {
1616
parser: require('recast/parsers/babel'),
1717
})

0 commit comments

Comments
 (0)