Skip to content
This repository was archived by the owner on May 16, 2019. It is now read-only.

Commit 3fd6aa4

Browse files
committed
Fix bug while edit unicode title of item
1 parent b590554 commit 3fd6aa4

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

market/contracts.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -923,6 +923,8 @@ def save(self):
923923
with open(file_path, 'w') as outfile:
924924
outfile.write(json.dumps(self.contract, indent=4))
925925

926+
if isinstance(self.previous_title, unicode):
927+
self.previous_title = self.previous_title.encode('utf8')
926928
if self.previous_title and self.previous_title != self.contract["vendor_offer"]["listing"]["item"]["title"]:
927929
old_name = str(self.previous_title[:100])
928930
old_name = re.sub(r"[^\w\s]", '', file_name)

0 commit comments

Comments
 (0)