Skip to content
Snippets Groups Projects
Commit a986c1c6 authored by Samuel GAIST's avatar Samuel GAIST
Browse files

[data][RemoteException] Fix __str__

The way the string returned by __str__ is created fails with
Python 3.
parent 1775a998
No related branches found
No related tags found
1 merge request!17Merge development branch 1.5.x
......@@ -65,10 +65,10 @@ class RemoteException(Exception):
self.user_error = message
def __str__(self):
if self.system_error != '':
return '(sys) ' + self.system_error
if self.system_error:
return '(sys) {}'.format(self.system_error)
else:
return '(usr) ' + self.user_error
return '(usr) {}'.format(self.user_error)
#----------------------------------------------------------
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment