Mercurial > hg
comparison mercurial/hgweb/hgweb_mod.py @ 6914:95f35b553ae6
hgweb: removed unnecessary del before function return
Deleting tmpl just before the return statement should have no effect
since tmpl goes out of scope anyway. But it confuses pyflakes who
thinks tmpl is undefined when it is used in the except blocks below.
author | Martin Geisler <mg@daimi.au.dk> |
---|---|
date | Sat, 16 Aug 2008 16:32:57 +0200 |
parents | 8909070fd05e |
children | 57b954d8d003 |
comparison
equal
deleted
inserted
replaced
6913:580d5e6bfc1f | 6914:95f35b553ae6 |
---|---|
166 else: | 166 else: |
167 content = getattr(webcommands, cmd)(self, req, tmpl) | 167 content = getattr(webcommands, cmd)(self, req, tmpl) |
168 req.respond(HTTP_OK, ctype) | 168 req.respond(HTTP_OK, ctype) |
169 | 169 |
170 req.write(content) | 170 req.write(content) |
171 del tmpl | |
172 return [] | 171 return [] |
173 | 172 |
174 except revlog.LookupError, err: | 173 except revlog.LookupError, err: |
175 req.respond(HTTP_NOT_FOUND, ctype) | 174 req.respond(HTTP_NOT_FOUND, ctype) |
176 msg = str(err) | 175 msg = str(err) |