browser: Fix crash when using HEAD on a page-matching URL

HEAD responses have no content, so it doesn't make sense to build
Pages out of them.
This commit is contained in:
Laurent Bachelier 2015-02-13 12:09:57 +01:00
commit 7d5835d84f

View file

@ -173,6 +173,8 @@ class URL(object):
"""
if self.klass is None:
return
if response.request.method == 'HEAD':
return
m = self.match(response.url)
if m: