} else {
// run a subset of the default comment listeners to figure out whether
// the comment is spam
CommentListener listener1 = new IpAddressListener();
CommentListener listener2 = new LinkSpamListener();
CommentListener listener3 = new ContentSpamListener();
CommentListener listener4 = new SpamScoreListener();
CommentEvent event = new CommentEvent(comment, CommentEvent.COMMENT_ADDED);
listener1.commentAdded(event);
listener2.commentAdded(event);
listener3.commentAdded(event);
listener4.commentAdded(event);
return (required != null && required.equalsIgnoreCase("true")) || !comment.isApproved();
}
}