Skip to content

Commit 763231e

Browse files
committed
fix(container): resolve remaining biome lint errors in setup.js
- Use template literal instead of string concat (line 109) - Add radix parameter to parseInt calls (line 157)
1 parent c8e6845 commit 763231e

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

container/setup.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@ function writeChecksums(codeforgeDir, version, checksums) {
106106
};
107107
fs.writeFileSync(
108108
path.join(checksumsDir, `${version}.json`),
109-
JSON.stringify(data, null, "\t") + "\n",
109+
`${JSON.stringify(data, null, "\t")}\n`,
110110
);
111111
}
112112

@@ -154,7 +154,9 @@ function readChecksums(codeforgeDir) {
154154
.sort((a, b) => {
155155
const parse = (v) => {
156156
const m = v.replace(".json", "").match(/^(\d+)\.(\d+)\.(\d+)/);
157-
return m ? [parseInt(m[1]), parseInt(m[2]), parseInt(m[3])] : [0, 0, 0];
157+
return m
158+
? [parseInt(m[1], 10), parseInt(m[2], 10), parseInt(m[3], 10)]
159+
: [0, 0, 0];
158160
};
159161
const pa = parse(a);
160162
const pb = parse(b);

0 commit comments

Comments
 (0)