Phyks (Lucas Verney)
Committed by Romain Bignon
Builds for 1 pipeline failed in 62 minutes 7 seconds

Fix an error with some URL parsing in explorimmo module, leading to last charact…

…er of the URL being truncated
......@@ -127,7 +127,10 @@ class SearchPage(HTMLPage):
if url:
url = unquote(url)
if "http://" in url[3:]:
url = url[url.find("http://", 3):url.rfind("?")]
rindex = url.rfind("?")
if rindex == -1:
rindex = None
url = url[url.find("http://", 3):rindex]
return [HousingPhoto(url)]
return NotAvailable