~nhanb/mcross

7bc4e56bcbabdf71b832ff04f943eda9310cc5ad — Bùi Thành Nhân 11 months ago 602a5db
fix bug when visiting relative url from root

https://todo.sr.ht/~nhanb/mcross/6
1 files changed, 2 insertions(+), 0 deletions(-)

M src/mcross/transport.py
M src/mcross/transport.py => src/mcross/transport.py +2 -0
@@ 91,6 91,8 @@ class GeminiUrl:
        #   raw url text: yikes
        #   => parsed url: gemini://example.com/foo/yikes
        current_path = current_url.path[: current_url.path.rfind("/") + 1]
        if current_path == "":
            current_path = "/"
        return GeminiUrl(current_url.host, current_url.port, current_path + text)

    @staticmethod