bug fix for URLs that fail when trying to follow redirects