From 08a53cdd2c5b541e2c5bd9a028b5b2e25d99cd5d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E3=81=82=E3=82=8F=E3=82=8F=E3=82=8F=E3=81=A8=E3=83=BC?= =?UTF-8?q?=E3=81=AB=E3=82=85?= <17376330+u1-liquid@users.noreply.github.com> Date: Thu, 19 Dec 2024 05:35:45 +0900 Subject: [PATCH] =?UTF-8?q?enhance(backend):=20blurhash=E7=94=9F=E6=88=90?= =?UTF-8?q?=E6=99=82=E3=80=81=E3=83=AA=E3=82=B5=E3=82=A4=E3=82=BA=E3=81=97?= =?UTF-8?q?=E3=81=A6=E3=81=8B=E3=82=89Raw=E3=81=AB=E5=A4=89=E6=8F=9B?= =?UTF-8?q?=E3=81=99=E3=82=8B=E3=82=88=E3=81=86=E3=81=AB=20(MisskeyIO#832)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/backend/src/core/FileInfoService.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/backend/src/core/FileInfoService.ts b/packages/backend/src/core/FileInfoService.ts index 31407db32..576eb089c 100644 --- a/packages/backend/src/core/FileInfoService.ts +++ b/packages/backend/src/core/FileInfoService.ts @@ -457,9 +457,9 @@ export class FileInfoService { private async getBlurhash(path: string, type: string): Promise { const sharp = await sharpBmp(path, type); const { data, info } = await sharp - .raw() - .ensureAlpha() .resize(64, 64, { fit: 'inside' }) + .ensureAlpha() + .raw() .toBuffer({ resolveWithObject: true }); return encode(new Uint8ClampedArray(data), info.width, info.height, 5, 5);