Fri Jul 22 06:15:21 UTC 2005 Alberto Bertogli <albertogli@telpin.com.ar>
* Fix fixu8 to support Python 2.3.
Some unicode stuff has changed in Python 2.4, so this change is needed to make
fixu8 work with older versions. It's not nice, but it does the trick and it
takes only a couple of self-contained lines.
Many people reported the problem and potential fixes, this one is by Markus
Keller <markus.keller@gmx.com>.
hunk ./darcsweb.cgi 76
- return s.decode(config.repoencoding).encode('utf8')
+ if type(s) == unicode:
+ # workaround for python < 2.4
+ return s.encode('utf8')
+ else:
+ return s.decode(config.repoencoding).encode('utf8')