1
0
mirror of https://github.com/BoostIo/Boostnote synced 2025-12-13 17:56:25 +00:00

Make image path relative

This commit is contained in:
asmsuechan
2017-07-26 13:02:44 +09:00
parent 0266770657
commit 044e6b7180
4 changed files with 18 additions and 5 deletions

View File

@@ -26,7 +26,7 @@ function copyImage (filePath, storageKey) {
if (!fs.existsSync(imageDir)) fs.mkdirSync(imageDir)
const outputImage = fs.createWriteStream(path.join(imageDir, basename))
inputImage.pipe(outputImage)
resolve(`${targetStorage.path}/images/${basename}`)
resolve(basename)
} catch (e) {
return reject(e)
}