Added dirty workaround to follow redirects on old php versions