remove avif support
All checks were successful
/ build (node-16) (push) Successful in 13s
/ build (windows-node-iron) (push) Successful in 54s

This commit is contained in:
Soph :3 2025-11-29 17:46:47 +02:00
parent a5109e1b20
commit 1eba3a92b2

View file

@ -5,7 +5,7 @@ export default class ImageOptimization extends Plugin {
build: undefined; build: undefined;
name = "image-optimization"; name = "image-optimization";
rewriteTriggers = ["png", "gif", "jpg", "jpeg", "webp", "avif"]; rewriteTriggers = ["png", "gif", "jpg", "jpeg", "webp"];
renameTo = "keep"; renameTo = "keep";
isBinary = true; isBinary = true;
longLasting = false; longLasting = false;
@ -25,9 +25,6 @@ export default class ImageOptimization extends Plugin {
if (type == "webp") { if (type == "webp") {
data = await sharp(file).webp({ lossless: true }).toBuffer(); data = await sharp(file).webp({ lossless: true }).toBuffer();
} }
if (type == "avif") {
data = await sharp(file).avif({ lossless: true }).toBuffer();
}
if (type == "jpg" || type == "jpeg") { if (type == "jpg" || type == "jpeg") {
data = await sharp(file).jpeg({ quality: 100 }).toBuffer(); data = await sharp(file).jpeg({ quality: 100 }).toBuffer();
} }