aboutsummaryrefslogtreecommitdiff
path: root/src/response.rs
diff options
context:
space:
mode:
authorFuwn <[email protected]>2023-05-17 02:12:20 -0700
committerFuwn <[email protected]>2023-05-17 02:12:20 -0700
commit0bc4ac8ba3a16aed491c3260d51406685cde2408 (patch)
tree164df292848c8ba9197ffb1607a7fa1ddcad37ed /src/response.rs
parentchore(tasks): simplify formatter (diff)
downloadlocus-0bc4ac8ba3a16aed491c3260d51406685cde2408.tar.xz
locus-0bc4ac8ba3a16aed491c3260d51406685cde2408.zip
deps(windmark): bump to 0.3.9
Diffstat (limited to 'src/response.rs')
-rw-r--r--src/response.rs6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/response.rs b/src/response.rs
index a8f8848..b368ba1 100644
--- a/src/response.rs
+++ b/src/response.rs
@@ -17,6 +17,8 @@
use std::sync::LazyLock;
+use windmark::response::Response;
+
static QUOTES: LazyLock<Vec<String>> = LazyLock::new(|| {
serde_json::from_str(include_str!("../content/json/quotes.json")).unwrap()
});
@@ -34,10 +36,10 @@ struct Main<'a> {
pub fn success(
body: &impl ToString,
context: &windmark::context::RouteContext,
-) -> windmark::Response {
+) -> Response {
crate::route::cache(context, &body.to_string());
- windmark::Response::success(
+ Response::success(
Main {
body: &body.to_string(),
hits: &crate::route::hits_from(context.url.path()),