mirror of
https://github.com/marktext/marktext.git
synced 2025-05-02 19:59:41 +08:00
Merge 9909d3b506
into 11c8cc1e19
This commit is contained in:
commit
557f4ae290
@ -154,7 +154,7 @@ export const uploadImage = async (pathname, image, preferences) => {
|
|||||||
if (typeof filepath !== 'string') {
|
if (typeof filepath !== 'string') {
|
||||||
isPath = false
|
isPath = false
|
||||||
const data = new Uint8Array(filepath)
|
const data = new Uint8Array(filepath)
|
||||||
filepath = path.join(tmpdir(), +new Date())
|
filepath = path.join(tmpdir(), +new Date() + ".png")
|
||||||
await fs.writeFile(filepath, data)
|
await fs.writeFile(filepath, data)
|
||||||
}
|
}
|
||||||
if (uploader === 'picgo') {
|
if (uploader === 'picgo') {
|
||||||
|
Loading…
Reference in New Issue
Block a user