Skip to content

Commit 7c80618

Browse files
committed
Update dependencies
1 parent f1262e3 commit 7c80618

File tree

3 files changed

+8
-6
lines changed

3 files changed

+8
-6
lines changed

bin/react-docgen.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ function traverseDir(path, result, done) {
114114
try {
115115
result[filename] = parser.parse(content);
116116
} catch(error) {
117-
writeError(error, path);
117+
writeError(error, filename);
118118
}
119119
next();
120120
},

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,11 @@
2727
"async": "^0.9.0",
2828
"node-dir": "^0.1.6",
2929
"nomnom": "^1.8.1",
30-
"recast": "^0.9.17"
30+
"recast": "^0.10.x"
3131
},
3232
"devDependencies": {
33-
"jest-cli": "^0.3.0",
34-
"react-tools": "^0.12.2"
33+
"jest-cli": "^0.4.0",
34+
"react-tools": "^0.13.x"
3535
},
3636
"jest": {
3737
"scriptPreprocessor": "./tests/preprocessor",

src/utils/docblock.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,10 @@ function parseDocblock(str) {
3131
*/
3232
function getDocblock(path: NodePath): ?string {
3333
if (path.node.comments) {
34-
var comments = path.node.comments.leading.filter(function(comment) {
35-
return comment.type === 'Block' && comment.value.indexOf('*\n') === 0;
34+
var comments = path.node.comments.filter(function(comment) {
35+
return comment.leading &&
36+
comment.type === 'Block' &&
37+
comment.value.indexOf('*\n') === 0;
3638
});
3739
if (comments.length > 0) {
3840
return parseDocblock(comments[comments.length - 1].value);

0 commit comments

Comments
 (0)