aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFuwn <[email protected]>2024-06-19 07:55:52 +0000
committerFuwn <[email protected]>2024-06-19 07:56:56 +0000
commit113bafa4ecb991ed2dfc0847faf356a0ab69767e (patch)
treecc9e1fbe6e35bd7fe0986f3bd37c746b5c2ca5e9
parentrefactor: remove long file headers (diff)
downloadseptember-113bafa4ecb991ed2dfc0847faf356a0ab69767e.tar.xz
september-113bafa4ecb991ed2dfc0847faf356a0ab69767e.zip
feat: bump september
-rw-r--r--Cargo.toml2
-rw-r--r--src/html.rs8
2 files changed, 8 insertions, 2 deletions
diff --git a/Cargo.toml b/Cargo.toml
index 2c3d80e..236cce7 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -2,7 +2,7 @@
[package]
name = "september"
-version = "0.2.17"
+version = "0.2.19"
authors = ["Fuwn <[email protected]>"]
edition = "2021"
description = "A simple and efficient Gemini-to-HTTP proxy."
diff --git a/src/html.rs b/src/html.rs
index 2574d8b..b35e41c 100644
--- a/src/html.rs
+++ b/src/html.rs
@@ -4,7 +4,13 @@ fn link_from_host_href(url: &Url, href: &str) -> Option<String> {
Some(format!(
"gemini://{}{}{}",
url.domain()?,
- { if href.starts_with('/') { "" } else { "/" } },
+ {
+ if href.starts_with('/') {
+ ""
+ } else {
+ "/"
+ }
+ },
href
))
}