Commit 2d21efc
committed
Fix off-by-one error in parameter count validation for scriptlets without parameters in
- Changed condition from `parameterIndex > 1` to `parameterIndex > 0` when checking for extra parameters
- Ensures scriptlets with no defined parameters correctly reject any parameters beyond scriptlet name
- Fixes duplicate error reporting where first parameter was incorrectly validated twice
- Updated documentation example to show correct single error for missing 'property' parameterno-invalid-scriptlets rule1 parent 52f58d3 commit 2d21efc
File tree
2 files changed
+1
-2
lines changed- docs/rules
- src/rules
2 files changed
+1
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
312 | 312 | | |
313 | 313 | | |
314 | 314 | | |
315 | | - | |
316 | 315 | | |
317 | 316 | | |
318 | 317 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
180 | 180 | | |
181 | 181 | | |
182 | 182 | | |
183 | | - | |
| 183 | + | |
184 | 184 | | |
185 | 185 | | |
186 | 186 | | |
| |||
0 commit comments