aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFuwn <[email protected]>2024-04-04 03:03:35 +0000
committerFuwn <[email protected]>2024-04-04 03:03:35 +0000
commit025d480736c552d8251b81d3bf61d7431c1e87cc (patch)
tree62ca68b8f36bb44c6167ca0a81f4c8c3d3f3e1ce
parentfeat(html): condense links option (diff)
downloadseptember-025d480736c552d8251b81d3bf61d7431c1e87cc.tar.xz
september-025d480736c552d8251b81d3bf61d7431c1e87cc.zip
deps(germ): bump to 0.4.0
-rw-r--r--Cargo.toml2
-rw-r--r--src/response.rs8
2 files changed, 6 insertions, 4 deletions
diff --git a/Cargo.toml b/Cargo.toml
index 4c3081e..71a7b72 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -21,7 +21,7 @@ opt-level = 3
[dependencies]
# Gemini
-germ = { version = "0.3.10", features = ["ast", "meta"] }
+germ = { version = "0.4.0", features = ["ast", "meta"] }
# HTTP
actix-web = "4.0.1"
diff --git a/src/response.rs b/src/response.rs
index bb77079..a3b1ae5 100644
--- a/src/response.rs
+++ b/src/response.rs
@@ -68,7 +68,7 @@ For example: to proxy "gemini://fuwn.me/uptime", visit "/proxy/fuwn.me/uptime".<
};
// Make a request to get Gemini content and time it.
let mut timer = Instant::now();
- let mut response = match germ::request::request(&url) {
+ let mut response = match germ::request::request(&url).await {
Ok(response) => response,
Err(e) => {
return Ok(HttpResponse::Ok().body(e.to_string()));
@@ -91,7 +91,9 @@ For example: to proxy "gemini://fuwn.me/uptime", visit "/proxy/fuwn.me/uptime".<
.body(format!("{e}")),
);
}
- }) {
+ })
+ .await
+ {
Ok(response) => response,
Err(e) => {
return Ok(HttpResponse::Ok().body(e.to_string()));
@@ -234,7 +236,7 @@ For example: to proxy "gemini://fuwn.me/uptime", visit "/proxy/fuwn.me/uptime".<
html_context.push_str(
&crate::html::from_gemini(
- &match germ::request::request(&redirect_url) {
+ &match germ::request::request(&redirect_url).await {
Ok(response) => response,
Err(e) => {
return Ok(HttpResponse::Ok().body(e.to_string()));