Generate backlinks
Some checks failed
CI / Check typos (push) Successful in 8s
CI / Clippy (push) Successful in 1m8s
CI / Build and test (push) Successful in 1m5s
CI / Check links (push) Failing after 1m16s
CI / Build container (push) Successful in 46s
CI / Deploy on waypoint (push) Successful in 45s

This commit is contained in:
2025-11-06 08:28:23 -08:00
parent 5554aafc44
commit b0f0038b24
12 changed files with 55 additions and 40 deletions

View File

@@ -15,7 +15,7 @@ pub struct PageMetadata {
pub author: Option<String>,
pub description: Option<String>,
pub image: Option<String>,
pub slug: Option<String>,
pub backlinks: Option<bool>,
}
impl Default for PageMetadata {
@@ -25,7 +25,7 @@ impl Default for PageMetadata {
author: None,
description: None,
image: None,
slug: None,
backlinks: None,
}
}
}

View File

@@ -3,6 +3,7 @@ use axum::http::HeaderMap;
#[derive(Debug, Clone, PartialEq, Eq, Hash)]
pub struct RequestContext {
pub client_info: ClientInfo,
pub route: String,
}
//

View File

@@ -170,7 +170,10 @@ impl PageServer {
device_type = ?client_info.device_type
);
let req_ctx = RequestContext { client_info };
let req_ctx = RequestContext {
client_info,
route: format!("/{route}"),
};
let cache_key = (route.clone(), req_ctx.clone());
let now = Utc::now();