fixed bug that made export fail on empty notes.