Skip to content

Commit 86a4d57

Browse files
committed
chore: remove what-comments and upstream references
1 parent 45cfa00 commit 86a4d57

2 files changed

Lines changed: 4 additions & 7 deletions

File tree

lib/rules/template-require-form-method.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,6 @@ function parseConfig(config) {
2626
}
2727
}
2828

29-
// Invalid configuration (e.g. unknown method in allowedMethods). Throw a
30-
// descriptive error to surface the problem to the user rather than silently
31-
// disabling the rule.
3229
throw new Error(
3330
'template-require-form-method: invalid configuration. Expected one of:\n' +
3431
' * boolean - `true` to enable / `false` to disable\n' +

tests/lib/rules/template-require-form-method.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@ const validHbs = [
99
options: [{ allowedMethods: ['get'] }],
1010
code: '<form method="GET"></form>',
1111
},
12-
// Default behavior: when no options are provided, the rule is disabled
13-
// (matching upstream ember-template-lint). A bare <form> should NOT error.
12+
// Default behavior: when no options are provided, the rule is disabled.
13+
// A bare <form> should NOT error.
1414
'<form></form>',
1515
'<form method="NOT_A_VALID_METHOD"></form>',
1616
{ options: [true], code: '<form method="POST"></form>' },
@@ -111,8 +111,8 @@ hbsRuleTester.run('template-require-form-method', rule, {
111111
invalid: invalidHbs,
112112
});
113113

114-
// Upstream-aligned error-surfacing tests. parseConfig should throw on an
115-
// invalid `allowedMethods` entry rather than silently disabling the rule.
114+
// parseConfig should throw on an invalid `allowedMethods` entry so that
115+
// misconfiguration is surfaced immediately rather than silently ignored.
116116
describe('template-require-form-method invalid configuration', () => {
117117
const { Linter } = require('eslint');
118118

0 commit comments

Comments
 (0)