fix: lint issues

!nuf
This commit is contained in:
Miodec 2025-04-16 19:39:07 +02:00
parent 0b05b3c2fd
commit bf0ce6607d
2 changed files with 3 additions and 3 deletions

View file

@ -450,7 +450,7 @@ export function getFunbox(
if (Array.isArray(nameOrNames)) {
const out = nameOrNames.map((name) => getObject()[name]);
//@ts-expect-error
//@ts-expect-error sanity check
if (out.includes(undefined)) {
throw new Error("One of the funboxes is invalid: " + nameOrNames);
}

View file

@ -110,13 +110,13 @@ const getCurrentVersion = () => {
const incrementVersion = (currentVersion) => {
console.log("Incrementing version...");
const now = new Date();
const year = now.getFullYear().toString().slice(-2);
const year = Number(now.getFullYear().toString().slice(-2));
const start = new Date(now.getFullYear(), 0, 1);
const week = Math.ceil(((now - start) / 86400000 + start.getDay() + 1) / 7);
const [prevYear, prevWeek, minor] = currentVersion.split(".").map(Number);
let newMinor = minor + 1;
if (year != prevYear || week != prevWeek) {
if (year !== prevYear || week !== prevWeek) {
newMinor = 0;
}