try to fix infinite redirects [ci skip]