Fix error when commentsOnly is true and file has no comments. Issue: #4