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

Change to use const instead of let

This commit is contained in:
asmsuechan
2017-03-10 20:40:11 -08:00
parent 65573bd4db
commit 0f3230110c

View File

@@ -167,11 +167,11 @@ export default class CodeEditor extends React.Component {
handleDropImage (e) {
e.preventDefault()
let imagePath = e.dataTransfer.files[0].path
let filename = path.basename(imagePath)
const imagePath = e.dataTransfer.files[0].path
const filename = path.basename(imagePath)
copyImage(imagePath, this.props.storageKey).then((imagePathInTheStorage) => {
let imageMd = `![${encodeURI(filename)}](${imagePathInTheStorage})`
const imageMd = `![${encodeURI(filename)}](${imagePathInTheStorage})`
this.insertImageMd(imageMd)
})
}