nagose commited on
Commit
d185783
1 Parent(s): 690bb8e

Update index.js

Browse files
Files changed (1) hide show
  1. index.js +1 -1
index.js CHANGED
@@ -61,7 +61,7 @@ app.get('/resize', async (req, res) => {
61
  res.setHeader('Access-Control-Allow-Methods', 'GET, POST, OPTIONS');
62
  res.setHeader('Access-Control-Allow-Headers', 'Content-Type');
63
  res.setHeader('Access-Control-Max-Age', '86400');
64
- res.send(fullUrl);
65
  } catch (error) {
66
  console.error('压缩图像时出错:', error);
67
  res.status(500).send('压缩图像时出错');
 
61
  res.setHeader('Access-Control-Allow-Methods', 'GET, POST, OPTIONS');
62
  res.setHeader('Access-Control-Allow-Headers', 'Content-Type');
63
  res.setHeader('Access-Control-Max-Age', '86400');
64
+ res.send(resizedImageBuffer);
65
  } catch (error) {
66
  console.error('压缩图像时出错:', error);
67
  res.status(500).send('压缩图像时出错');