1
0
mirror of https://github.com/BoostIo/Boostnote synced 2025-12-13 09:46:22 +00:00

Fix exportFolder error

writeFileSync doesn't require any errors
This commit is contained in:
Junyoung Choi
2018-01-13 18:48:34 +09:00
parent 3e9b28ff0c
commit c36ecb1ed1

View File

@@ -46,9 +46,7 @@ function exportFolder (storageKey, folderKey, fileType, exportDir) {
.filter(note => note.folder === folderKey && note.isTrashed === false && note.type === 'MARKDOWN_NOTE')
.forEach(snippet => {
const notePath = path.join(exportDir, `${snippet.title}.${fileType}`)
fs.writeFileSync(notePath, snippet.content, (err) => {
if (err) throw err
})
fs.writeFileSync(notePath, snippet.content)
})
return {