##// END OF EJS Templates
scmutil: avoid using basestring and add explicit handling of unicodes...
Augie Fackler -
r36679:b76248e5 default
parent child Browse files
Show More
@@ -186,7 +186,10 b' def callcatch(ui, func):'
186 ui.warn(_("(%s)\n") % inst.hint)
186 ui.warn(_("(%s)\n") % inst.hint)
187 except error.ResponseError as inst:
187 except error.ResponseError as inst:
188 ui.warn(_("abort: %s") % inst.args[0])
188 ui.warn(_("abort: %s") % inst.args[0])
189 if not isinstance(inst.args[1], basestring):
189 msg = inst.args[1]
190 if isinstance(msg, type(u'')):
191 msg = pycompat.sysbytes(msg)
192 elif not isinstance(inst.args[1], bytes):
190 ui.warn(" %r\n" % (inst.args[1],))
193 ui.warn(" %r\n" % (inst.args[1],))
191 elif not inst.args[1]:
194 elif not inst.args[1]:
192 ui.warn(_(" empty string\n"))
195 ui.warn(_(" empty string\n"))
General Comments 0
You need to be logged in to leave comments. Login now