diff --git a/pubky/pkg/package.json b/pubky/pkg/package.json index 34e6409..657e1d0 100644 --- a/pubky/pkg/package.json +++ b/pubky/pkg/package.json @@ -2,7 +2,7 @@ "name": "@synonymdev/pubky", "type": "module", "description": "Pubky client", - "version": "0.4.0-rc2", + "version": "0.4.0-rc3", "license": "MIT", "repository": { "type": "git", diff --git a/pubky/src/wasm/http.rs b/pubky/src/wasm/http.rs index eea495d..2fe2291 100644 --- a/pubky/src/wasm/http.rs +++ b/pubky/src/wasm/http.rs @@ -150,8 +150,11 @@ impl Client { url.set_port(Some(http_port)) .expect("coultdn't use the resolved endpoint's port"); } else { - url.set_port(Some(e.port())) - .expect("coultdn't use the resolved endpoint's port"); + // TODO: where does port zero come from? + if e.port() != 0 { + url.set_port(Some(e.port())) + .expect("coultdn't use the resolved endpoint's port"); + } } url.set_host(Some(e.domain()))