Skip to content

Commit 2df802f

Browse files
NullVoxPopuliclaude
andcommitted
Fix prettier formatting
Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]>
1 parent c981dfa commit 2df802f

2 files changed

Lines changed: 3 additions & 8 deletions

File tree

lib/processors/template-lint-disable.js

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,8 @@ const noop = require('ember-eslint-parser/noop');
88
* {{! template-lint-disable rule1 rule2 }}
99
* {{!-- template-lint-disable rule1 rule2 --}}
1010
*/
11-
const MUSTACHE_COMMENT_REGEX =
12-
/{{!\s+template-lint-disable([\s\w,/-]*)}}/g;
13-
const MUSTACHE_BLOCK_COMMENT_REGEX =
14-
/{{!--\s*template-lint-disable([\s\w,/-]*)--}}/g;
11+
const MUSTACHE_COMMENT_REGEX = /{{!\s+template-lint-disable([\s\w,/-]*)}}/g;
12+
const MUSTACHE_BLOCK_COMMENT_REGEX = /{{!--\s*template-lint-disable([\s\w,/-]*)--}}/g;
1513

1614
// Store disable directives per file
1715
const fileDisableDirectives = new Map();
@@ -29,9 +27,7 @@ function collectMatches(line, lineIndex, directives) {
2927

3028
while ((match = regex.exec(line)) !== null) {
3129
const rulesPart = (match[1] || '').trim();
32-
const rules = rulesPart
33-
? rulesPart.split(/[\s,]+/).filter(Boolean)
34-
: []; // empty = disable all
30+
const rules = rulesPart ? rulesPart.split(/[\s,]+/).filter(Boolean) : []; // empty = disable all
3531

3632
// Comment is on line lineIndex+1 (1-indexed), next line is lineIndex+2.
3733
// In template ASTs, TextNodes can start on the same line as the comment

tests/lib/rules-preprocessor/gjs-gts-parser-test.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1046,4 +1046,3 @@ describe('supports template-lint-disable directive', () => {
10461046
expect(resultErrors).toHaveLength(0);
10471047
});
10481048
});
1049-

0 commit comments

Comments
 (0)