Skip to content

Commit 7f7b6e4

Browse files
author
Alexej Yaroshevich
committed
checkRedundantReturns: dropped return type checking
Ref #82
1 parent 9da8725 commit 7f7b6e4

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/rules/validate-jsdoc/check-redundant-returns.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,9 +18,9 @@ function checkReturnTypes(node, tag, err) {
1818
}
1919

2020
// checking redundant: invalid or not return statements in code
21-
var redundant = !tag.type.valid || !this._getReturnStatementsForNode(node).length;
21+
var redundant = !Boolean(this._getReturnStatementsForNode(node).length);
2222

2323
if (redundant) {
24-
err('redundant returns statement');
24+
err('Redundant return statement', tag.loc);
2525
}
2626
}

0 commit comments

Comments
 (0)