diff options
author | Vika <vika@fireburn.ru> | 2023-06-22 21:35:22 +0300 |
---|---|---|
committer | Vika <vika@fireburn.ru> | 2023-06-22 21:35:22 +0300 |
commit | 858c0ddd9cc36af0acc72efb1ff1bdc1d8e28b0a (patch) | |
tree | 5b46bcc88e37fa0e23fea4f49c0242ad21662bca /kittybox-rs/src/frontend/mod.rs | |
parent | d61e1f6a8e5ad5b7c14b1f9ab3101496f3f9ea00 (diff) | |
download | kittybox-858c0ddd9cc36af0acc72efb1ff1bdc1d8e28b0a.tar.zst |
database: use domains instead of authorities as owner key
This allows disregarding http/https comparisons and simplifies some database designs.
Diffstat (limited to 'kittybox-rs/src/frontend/mod.rs')
-rw-r--r-- | kittybox-rs/src/frontend/mod.rs | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/kittybox-rs/src/frontend/mod.rs b/kittybox-rs/src/frontend/mod.rs index d677005..ed3932b 100644 --- a/kittybox-rs/src/frontend/mod.rs +++ b/kittybox-rs/src/frontend/mod.rs @@ -132,13 +132,13 @@ pub async fn homepage<D: Storage>( // // btw is it more efficient to fetch these in parallel? let (blogname, webring, channels) = tokio::join!( - db.get_setting::<crate::database::settings::SiteName>(&path) + db.get_setting::<crate::database::settings::SiteName>(&host) .map(Result::unwrap_or_default), - db.get_setting::<crate::database::settings::Webring>(&path) + db.get_setting::<crate::database::settings::Webring>(&host) .map(Result::unwrap_or_default), - db.get_channels(&path).map(|i| i.unwrap_or_default()) + db.get_channels(&host).map(|i| i.unwrap_or_default()) ); // Render the homepage ( @@ -176,10 +176,10 @@ pub async fn homepage<D: Storage>( error!("Error while fetching h-card and/or h-feed: {}", err); // Return the error let (blogname, channels) = tokio::join!( - db.get_setting::<crate::database::settings::SiteName>(&path) + db.get_setting::<crate::database::settings::SiteName>(&host) .map(Result::unwrap_or_default), - db.get_channels(&path).map(|i| i.unwrap_or_default()) + db.get_channels(&host).map(|i| i.unwrap_or_default()) ); ( |