Skip to content

Commit 04fbd81

Browse files
committed
chore: bump oxlint version
1 parent 0bf76e8 commit 04fbd81

File tree

16 files changed

+554
-429
lines changed

16 files changed

+554
-429
lines changed

backend/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@
9393
"eslint-watch": "8.0.0",
9494
"ioredis-mock": "7.4.0",
9595
"openapi3-ts": "2.0.2",
96-
"oxlint": "0.16.7",
96+
"oxlint": "0.16.12",
9797
"readline-sync": "1.4.10",
9898
"supertest": "6.2.3",
9999
"tsx": "4.16.2",

frontend/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@
6161
"madge": "8.0.0",
6262
"magic-string": "0.30.17",
6363
"normalize.css": "8.0.1",
64-
"oxlint": "0.16.7",
64+
"oxlint": "0.16.12",
6565
"postcss": "8.4.31",
6666
"sass": "1.70.0",
6767
"subset-font": "2.3.0",

frontend/src/ts/commandline/commandline.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -119,9 +119,9 @@ export function show(
119119
let showInputCommand: Command | undefined = undefined;
120120

121121
if (settings?.commandOverride !== undefined) {
122-
const command = (await getList()).filter(
122+
const command = (await getList()).find(
123123
(c) => c.id === settings.commandOverride
124-
)[0];
124+
);
125125
if (command === undefined) {
126126
Notifications.add(`Command ${settings.commandOverride} not found`, 0);
127127
} else if (command?.input !== true) {

frontend/src/ts/controllers/challenge-controller.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -230,9 +230,9 @@ export async function setup(challengeName: string): Promise<boolean> {
230230
return false;
231231
}
232232

233-
const challenge = list.filter(
233+
const challenge = list.find(
234234
(c) => c.name.toLowerCase() === challengeName.toLowerCase()
235-
)[0];
235+
);
236236
let notitext;
237237
try {
238238
if (challenge === undefined) {

frontend/src/ts/db.ts

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -746,9 +746,7 @@ export async function getLocalTagPB<M extends Mode>(
746746

747747
let ret = 0;
748748

749-
const filteredtag = (getSnapshot()?.tags ?? []).filter(
750-
(t) => t._id === tagId
751-
)[0];
749+
const filteredtag = (getSnapshot()?.tags ?? []).find((t) => t._id === tagId);
752750

753751
if (filteredtag === undefined) return ret;
754752

@@ -800,9 +798,9 @@ export async function saveLocalTagPB<M extends Mode>(
800798
if (!dbSnapshot) return;
801799
if (mode === "quote") return;
802800
function cont(): void {
803-
const filteredtag = dbSnapshot?.tags?.filter(
801+
const filteredtag = dbSnapshot?.tags?.find(
804802
(t) => t._id === tagId
805-
)[0] as SnapshotUserTag;
803+
) as SnapshotUserTag;
806804

807805
filteredtag.personalBests ??= {
808806
time: {},

frontend/src/ts/elements/account/result-filters.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -425,9 +425,9 @@ export function updateActive(): void {
425425
if (id === "none") return id;
426426
const snapshot = DB.getSnapshot();
427427
if (snapshot === undefined) return id;
428-
const name = snapshot.tags?.filter((t) => t._id === id)[0];
428+
const name = snapshot.tags?.find((t) => t._id === id);
429429
if (name !== undefined) {
430-
return snapshot.tags?.filter((t) => t._id === id)[0]?.display;
430+
return snapshot.tags?.find((t) => t._id === id)?.display;
431431
}
432432
return name;
433433
})

frontend/src/ts/modals/edit-preset.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -279,9 +279,9 @@ async function apply(): Promise<void> {
279279
} as SnapshotPreset);
280280
}
281281
} else if (action === "edit") {
282-
const preset = snapshotPresets.filter(
282+
const preset = snapshotPresets.find(
283283
(preset: SnapshotPreset) => preset._id === presetId
284-
)[0] as SnapshotPreset;
284+
) as SnapshotPreset;
285285
if (preset === undefined) {
286286
Notifications.add("Preset not found", -1);
287287
return;

frontend/src/ts/utils/animated-modal.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -182,9 +182,7 @@ export default class AnimatedModal<
182182

183183
focusFirstInput(setting: true | "focusAndSelect" | undefined): void {
184184
const inputs = [...this.modalEl.querySelectorAll("input")];
185-
const input = inputs.filter(
186-
(input) => !input.classList.contains("hidden")
187-
)[0];
185+
const input = inputs.find((input) => !input.classList.contains("hidden"));
188186
if (input !== undefined && input !== null) {
189187
if (setting === true) {
190188
input.focus();

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@
7272
"knip": "2.19.2",
7373
"lint-staged": "13.2.3",
7474
"only-allow": "1.2.1",
75-
"oxlint": "0.16.7",
75+
"oxlint": "0.16.12",
7676
"prettier": "2.8.8",
7777
"turbo": "2.3.3",
7878
"vitest": "2.1.9"

packages/contracts/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
"chokidar": "3.6.0",
2323
"eslint": "8.57.1",
2424
"madge": "8.0.0",
25-
"oxlint": "0.16.7",
25+
"oxlint": "0.16.12",
2626
"tsup": "8.4.0",
2727
"typescript": "5.5.4",
2828
"vitest": "2.1.9"

0 commit comments

Comments
 (0)