From 3afc2a983c3ca6d91928d532fea43c93c7fa9234 Mon Sep 17 00:00:00 2001 From: Antoine Nguyen Date: Fri, 4 Aug 2017 09:51:03 +0200 Subject: [PATCH] We need str objects here. see #1207 --- modoboa/core/models.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/modoboa/core/models.py b/modoboa/core/models.py index d728c203c..0d2b203f4 100644 --- a/modoboa/core/models.py +++ b/modoboa/core/models.py @@ -365,14 +365,14 @@ class User(AbstractUser): :param csvwriter: csv object """ row = [ - b"account", - smart_bytes(self.username), - smart_bytes(self.password), - smart_bytes(self.first_name), - smart_bytes(self.last_name), - smart_bytes(self.is_active), - smart_bytes(self.role), - smart_bytes(self.email) + "account", + force_str(self.username), + force_str(self.password), + force_str(self.first_name), + force_str(self.last_name), + force_str(self.is_active), + force_str(self.role), + force_str(self.email) ] results = signals.account_exported.send( sender=self.__class__, user=self)