Khrisna commited on
Commit
8e129e0
·
verified ·
1 Parent(s): 0f76635

Update lib/converter.js

Browse files
Files changed (1) hide show
  1. lib/converter.js +1 -1
lib/converter.js CHANGED
@@ -6,7 +6,7 @@ function convertWebpToPng(input) {
6
  try {
7
  if (typeof input === "string") {
8
  const response = await fetch(input);
9
- const images = await response.buffer();
10
  const converting = await sharp(images);
11
  const converted = converting.toFormat('png').png({ quality: 90 }).toBuffer();
12
  resolve(converted);
 
6
  try {
7
  if (typeof input === "string") {
8
  const response = await fetch(input);
9
+ const images = await response.arrayBuffer();
10
  const converting = await sharp(images);
11
  const converted = converting.toFormat('png').png({ quality: 90 }).toBuffer();
12
  resolve(converted);