chore: Enable more lint rules, disable some that trigger a lot. Will clean up later.

This commit is contained in:
cpojer
2026-01-31 16:03:28 +09:00
parent 481f696a87
commit 15792b153f
292 changed files with 643 additions and 699 deletions
+1 -1
View File
@@ -350,7 +350,7 @@ export async function hasAlphaChannel(buffer: Buffer): Promise<boolean> {
// Check if the image has an alpha channel
// PNG color types with alpha: 4 (grayscale+alpha), 6 (RGBA)
// Sharp reports this via 'channels' (4 = RGBA) or 'hasAlpha'
return meta.hasAlpha === true || meta.channels === 4;
return meta.hasAlpha || meta.channels === 4;
} catch {
return false;
}
+3 -3
View File
@@ -58,14 +58,14 @@ describe("media store redirects", () => {
res.statusCode = 302;
res.headers = { location: "https://example.com/final" };
setImmediate(() => {
cb(res as unknown as Parameters<typeof cb>[0]);
cb(res as unknown);
res.end();
});
} else {
res.statusCode = 200;
res.headers = { "content-type": "text/plain" };
setImmediate(() => {
cb(res as unknown as Parameters<typeof cb>[0]);
cb(res as unknown);
res.write("redirected");
res.end();
});
@@ -98,7 +98,7 @@ describe("media store redirects", () => {
res.statusCode = 200;
res.headers = {};
setImmediate(() => {
cb(res as unknown as Parameters<typeof cb>[0]);
cb(res as unknown);
const zip = new JSZip();
zip.file(
"[Content_Types].xml",