Add some tests for comment-filters through api
Also never bother comment options to filter comment5/shebang comments as they have their custom filter.
This commit is contained in:
committed by
Richard van Velzen
parent
57e0fafd5c
commit
70e5b6f15b
@@ -444,11 +444,11 @@ function OutputStream(options) {
|
||||
});
|
||||
} else if (c.test) {
|
||||
comments = comments.filter(function(comment){
|
||||
return c.test(comment.value) || comment.type == "comment5";
|
||||
return comment.type == "comment5" || c.test(comment.value);
|
||||
});
|
||||
} else if (typeof c == "function") {
|
||||
comments = comments.filter(function(comment){
|
||||
return c(self, comment) || comment.type == "comment5";
|
||||
return comment.type == "comment5" || c(self, comment);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user