Fix string decode error when importing csv files

This commit is contained in:
Carl Hofmeister 2017-12-31 14:01:47 -06:00
parent 5ad8f67f12
commit baee6916e7

View File

@ -74,7 +74,7 @@ class TextImporter(NoteImporter):
self.data = [sub(x)+"\n" for x in self.data.split("\n") if sub(x) != "__comment"] self.data = [sub(x)+"\n" for x in self.data.split("\n") if sub(x) != "__comment"]
if self.data: if self.data:
if self.data[0].startswith("tags:"): if self.data[0].startswith("tags:"):
tags = str(self.data[0][5:], "utf8").strip() tags = str(self.data[0][5:]).strip()
self.tagsToAdd = tags.split(" ") self.tagsToAdd = tags.split(" ")
del self.data[0] del self.data[0]
self.updateDelimiter() self.updateDelimiter()