Skip to content

Commit 5fda732

Browse files
committed
Fix bug in grammar header detection
1 parent bcbd294 commit 5fda732

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

.github/algorithm-format-check.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ for (const filename of filenames) {
9494
// Still grammar, not algorithm
9595
continue;
9696
}
97-
if (lines[i + 1] !== "") {
97+
if (rest.trim() === "" && lines[i + 1] !== "") {
9898
console.log(
9999
`No empty space after grammar ${grammarName} header in '${filename}'`
100100
);

0 commit comments

Comments
 (0)