Add oxlint config and fix unicorn/no-array-sort violation
Some checks failed
🚀 Deploy / ʦ TypeScript (pull_request) Has been cancelled
🚀 Deploy / 🔍 Lint (pull_request) Has been cancelled
🚀 Deploy / 🐳 Build (pull_request) Has been cancelled
🚀 Deploy / 🚀 Deploy (pull_request) Has been cancelled
🚀 Deploy / 🧪 Test (pull_request) Has been cancelled

Promote unicorn/no-array-sort to error in oxlint.json and replace
[...teams].sort() with teams.toSorted() in discord.ts.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
Chris Parsons 2026-05-21 17:01:02 -07:00
parent 0b8f7edc08
commit 2192f1790d
2 changed files with 6 additions and 1 deletions

View file

@ -208,7 +208,7 @@ export async function sendDraftOrderNotification({
? `Draft Order Manually Set — ${leagueName}` ? `Draft Order Manually Set — ${leagueName}`
: `Draft Order Randomized — ${leagueName}`; : `Draft Order Randomized — ${leagueName}`;
const sorted = [...teams].sort((a, b) => a.position - b.position); const sorted = teams.toSorted((a, b) => a.position - b.position);
let description = sorted let description = sorted
.map((t) => { .map((t) => {
const teamLabel = escapeMarkdown(t.name); const teamLabel = escapeMarkdown(t.name);

5
oxlint.json Normal file
View file

@ -0,0 +1,5 @@
{
"rules": {
"unicorn/no-array-sort": "error"
}
}