hgweb: fix breakage in python < 2.5 introduced in 2c370f08c486
authorDirkjan Ochtman <dirkjan@ochtman.nl>
Mon, 24 Mar 2008 16:20:15 +0100
changeset 6374 31a01e3d99cc
parent 6373 7010e4557963
child 6375 cdc458b12f0f
child 6376 b40e90341ae2
hgweb: fix breakage in python < 2.5 introduced in 2c370f08c486
mercurial/hgweb/hgweb_mod.py
--- a/mercurial/hgweb/hgweb_mod.py	Sun Mar 23 21:35:57 2008 -0300
+++ b/mercurial/hgweb/hgweb_mod.py	Mon Mar 24 16:20:15 2008 +0100
@@ -248,9 +248,8 @@
 
         except revlog.LookupError, err:
             req.respond(HTTP_NOT_FOUND, ctype)
-            if 'manifest' in err.message:
-                msg = str(err)
-            else:
+            msg = str(err)
+            if 'manifest' not in msg:
                 msg = 'revision not found: %s' % err.name
             req.write(tmpl('error', error=msg))
         except (RepoError, revlog.RevlogError), inst: