Skip to content

Commit

Permalink
chore: use named exports of bmpjs
Browse files Browse the repository at this point in the history
  • Loading branch information
magicdawn committed Dec 20, 2023
1 parent d01db2c commit 9d9f406
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/compress.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import * as bmp from '@vingle/bmp-js'
import { decode as bmpDecode } from '@vingle/bmp-js'
import { readFile } from 'fs/promises'
import NodeMozjpeg, { type EncodeOptions as MozjpegEncodeOptions } from 'node-mozjpeg'
import path from 'path'
Expand Down Expand Up @@ -33,7 +33,7 @@ function isBitmap(buf: Buffer): boolean {
}

const handleBmp = (buf: Buffer) => {
const bitmap = bmp.decode(buf, true)
const bitmap = bmpDecode(buf, true)
return sharp(bitmap.data, {
raw: {
width: bitmap.width,
Expand Down

0 comments on commit 9d9f406

Please sign in to comment.