Skip to content

Commit c54ac67

Browse files
committed
🐛 Fix: auto generate a local png bug
1 parent 12ec75d commit c54ac67

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

src/utils/getURLFile.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ import PicGo from '../core/PicGo'
22
import request from 'request'
33
import path from 'path'
44
import { IPathTransformedImgInfo } from './interfaces'
5-
import fs from 'fs'
65

76
export const getURLFile = async (ctx: PicGo, url: string): Promise<IPathTransformedImgInfo> => {
87
const requestOptions = {
@@ -26,7 +25,6 @@ export const getURLFile = async (ctx: PicGo, url: string): Promise<IPathTransfor
2625
})
2726
clearTimeout(timeoutId)
2827
if (isImage) {
29-
fs.writeFileSync('./logo.png', res)
3028
resolve({
3129
buffer: res,
3230
fileName: path.basename(requestOptions.url.split('?')[0]),

0 commit comments

Comments
 (0)