From 5778e1196e5adbae77e5a05bd7cfb4879b012739 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Kamil=20Og=C3=B3rek?= Date: Fri, 10 Feb 2023 16:11:11 +0100 Subject: feat(install): follow redirects for urls with no path (#17449) This change makes absolute urls, that contain no path like `deno install https://my-cli.io` to follow redirects and extract the name from it. It allows modifies `test_util` server listener on port `4550` (`REDIRECT_ABSOLUTE_PORT`) to allow for specifying `redirect_to` query param, that fill use that value for it's next redirect. Fixes https://github.com/denoland/deno/issues/17409 --- cli/http_util.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'cli/http_util.rs') diff --git a/cli/http_util.rs b/cli/http_util.rs index 225c49996..9476d6a5f 100644 --- a/cli/http_util.rs +++ b/cli/http_util.rs @@ -300,7 +300,7 @@ impl HttpClient { .map(Some) } - async fn get_redirected_response( + pub async fn get_redirected_response( &self, url: U, ) -> Result { -- cgit v1.2.3