From 9924c51c8087beace7b8406bc44780c5c59ff2ff Mon Sep 17 00:00:00 2001 From: Jack Stdin Date: Mon, 15 Feb 2016 12:40:34 +0300 Subject: [PATCH] Add utf-8 decode for postgres query --- aore/fias/wordentry.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/aore/fias/wordentry.py b/aore/fias/wordentry.py index 41f9795..e76833c 100644 --- a/aore/fias/wordentry.py +++ b/aore/fias/wordentry.py @@ -44,7 +44,7 @@ class WordEntry: def __init__(self, db, word): self.db = db - self.word = unicode(word) + self.word = str(word).decode('utf8') self.word_len = len(unicode(self.word)) self.variations = [] self.scname = None