try to prevent redirect loop