Skip to content

Commit e59f465

Browse files
committed
fix: resolve rebase fallout
Missing brace in printViolations grouping loop, stray rule-object closers in plugin.js, TS18048 on optional v.line in sort comparator.
1 parent 9a03226 commit e59f465

3 files changed

Lines changed: 2 additions & 4 deletions

File tree

rules/plugin.js

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -108,9 +108,6 @@ const plugin = {
108108
};
109109
},
110110
},
111-
};
112-
},
113-
},
114111

115112
/**
116113
* Disallow `throw new Error(...)` in favor of custom error classes.

src/commands/lint.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ describe('lint command', () => {
132132
const violations = await runOxlint(['./src']);
133133
const maxParams = violations.filter((v) => v.code === 'bombshell-dev(max-params)');
134134

135-
expect(maxParams.map((v) => v.line).sort((a, b) => a - b)).toEqual([2, 3, 4, 11]);
135+
expect(maxParams.map((v) => v.line!).sort((a, b) => a - b)).toEqual([2, 3, 4, 11]);
136136
});
137137
});
138138

src/commands/lint.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -281,6 +281,7 @@ export function printViolations(violations: Violation[], options?: { warnings?:
281281
const key = v.file ?? '(project)';
282282
if (!grouped.has(key)) grouped.set(key, []);
283283
grouped.get(key)!.push(v);
284+
}
284285

285286
for (const [file, items] of grouped) {
286287
console.log(`\n${file}`);

0 commit comments

Comments
 (0)