twikoo-vercel 1.5.6 → 1.5.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/api/index.js +0 -18
  2. package/package.json +1 -1
package/api/index.js CHANGED
@@ -1458,24 +1458,6 @@ async function uploadImage (event) {
1458
1458
  return res
1459
1459
  }
1460
1460
 
1461
- async function uploadImageTo7Bu ({ photo, fileName, config, res }) {
1462
- // 去不图床旧版本 https://7bu.top
1463
- // TODO: 2022 年 4 月 30 日后去不图床将会升级新版本,此处逻辑要同步更新
1464
- const formData = new FormData()
1465
- formData.append('image', base64UrlToReadStream(photo, fileName))
1466
- const uploadResult = await axios.post('https://7bu.top/api/upload', formData, {
1467
- headers: {
1468
- ...formData.getHeaders(),
1469
- token: config.IMAGE_CDN_TOKEN
1470
- }
1471
- })
1472
- if (uploadResult.data.code === 200) {
1473
- res.data = uploadResult.data.data
1474
- } else {
1475
- throw new Error(uploadResult.data.msg)
1476
- }
1477
- }
1478
-
1479
1461
  async function uploadImageToSmms ({ photo, fileName, config, res }) {
1480
1462
  // SM.MS 图床 https://sm.ms
1481
1463
  const formData = new FormData()
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "twikoo-vercel",
3
- "version": "1.5.6",
3
+ "version": "1.5.7",
4
4
  "description": "A simple comment system based on Tencent CloudBase (tcb).",
5
5
  "author": "imaegoo <hello@imaegoo.com> (https://github.com/imaegoo)",
6
6
  "license": "MIT",