geminispace.info

gemini search engine
git clone https://git.clttr.info/geminispace.info.git
Log (Feed) | Files | Refs (Tags) | README | LICENSE

commit f1accd3f44a9fb0317c6e934ba35cc44c6a0d347
parent 570363cf9a3339532bbead6413b6bcb53c4ec377
Author: René Wagner <rwa@clttr.info>
Date:   Fri, 19 Nov 2021 16:06:37 +0100

don't crash on URIs with non-number port

closes #37

Diffstat:
Mgus/lib/gemini.py | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gus/lib/gemini.py b/gus/lib/gemini.py @@ -392,7 +392,7 @@ class GeminiResource: def _get_normalized_url_and_host(self): url_normalized = unquote(self.fetchable_url.rstrip("/")) - if self.urlsplit.port == 1965: + if self.urlsplit.port == "1965": url_normalized = url_normalized.replace( self.urlsplit.hostname.lower() + ":1965", self.urlsplit.hostname.lower(),