# HG changeset patch # User Dirkjan Ochtman # Date 2008-03-24 15:20:15 # Node ID 31a01e3d99ccbbd2e74f2c3c43001ace8af636ea # Parent 7010e45579637528a41867046ee360b28682c26a hgweb: fix breakage in python < 2.5 introduced in 2c370f08c486 diff --git a/mercurial/hgweb/hgweb_mod.py b/mercurial/hgweb/hgweb_mod.py --- a/mercurial/hgweb/hgweb_mod.py +++ b/mercurial/hgweb/hgweb_mod.py @@ -248,9 +248,8 @@ class hgweb(object): 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: