enml2md
enml2md copied to clipboard
TypeError: Cannot read property 'exportFileName' of undefined
$ node bin/enml2md Recipes.enex ./Recipes
/home/omega9/Warehouse/Sources/Evernote/enml2md/lib/Note.js:63
attachmentFileName = attachment.exportFileName();
^
TypeError: Cannot read property 'exportFileName' of undefined
at null.<anonymous> (/home/omega9/Warehouse/Sources/Evernote/enml2md/lib/Note.js:63:40)
at exports.each (/home/omega9/Warehouse/Sources/Evernote/enml2md/node_modules/cheerio/lib/api/traversing.js:122:24)
at Note.loadENMLContent (/home/omega9/Warehouse/Sources/Evernote/enml2md/lib/Note.js:58:21)
at Function.Note.composeNoteWithCheerio (/home/omega9/Warehouse/Sources/Evernote/enml2md/lib/Note.js:103:10)
at null.<anonymous> (/home/omega9/Warehouse/Sources/Evernote/enml2md/lib/Parser.js:28:23)
at exports.each (/home/omega9/Warehouse/Sources/Evernote/enml2md/node_modules/cheerio/lib/api/traversing.js:122:24)
at /home/omega9/Warehouse/Sources/Evernote/enml2md/lib/Parser.js:25:19
at fs.js:334:14
at /home/omega9/Warehouse/Sources/Evernote/enml2md/node_modules/graceful-fs/graceful-fs.js:103:5
at FSReqWrap.oncomplete (fs.js:95:15)
@Omega9:
I encountered the same issue. It seems Evernote doesn't always synch attachment content for all notes. When I click on older notes, it downloads the attachments on demand. When exporting notes in this state, the <resource>
element the .enex is missing it's <data>
element.
This contradicts the info in the export dialog:
This will export the selected notes into a single XML file that preserves exact note content with attachments.
I think this is an Evernote bug (and another reason to stop using Evernote as soon as possible).