mirror of
https://github.com/misskey-dev/misskey.git
synced 2024-12-26 17:00:19 +01:00
enhance(backend): blurhash生成時、リサイズしてからRawに変換するように (MisskeyIO#832)
This commit is contained in:
parent
e8bf6285cb
commit
583e4b4fa1
1 changed files with 2 additions and 2 deletions
|
@ -458,9 +458,9 @@ export class FileInfoService {
|
|||
private getBlurhash(path: string, type: string): Promise<string> {
|
||||
return new Promise(async (resolve, reject) => {
|
||||
(await sharpBmp(path, type))
|
||||
.raw()
|
||||
.ensureAlpha()
|
||||
.resize(64, 64, { fit: 'inside' })
|
||||
.ensureAlpha()
|
||||
.raw()
|
||||
.toBuffer((err, buffer, info) => {
|
||||
if (err) return reject(err);
|
||||
|
||||
|
|
Loading…
Reference in a new issue