about summary refs log tree commit diff
path: root/kittybox-rs/src/indieauth
diff options
context:
space:
mode:
authorVika <vika@fireburn.ru>2023-06-15 22:44:50 +0300
committerVika <vika@fireburn.ru>2023-06-15 22:44:50 +0300
commit2f5df555ecf70dbaf7f059723813ea099e12879d (patch)
tree57b9e0a951ae21859342cf3f1a456c999a5c750d /kittybox-rs/src/indieauth
parent9a28da3ac18f60329474e6b48a77f07e57ba88d4 (diff)
downloadkittybox-2f5df555ecf70dbaf7f059723813ea099e12879d.tar.zst
Smallish code tweaks
 - cleaner format!()
 - syndication links
 - broke up a long line
Diffstat (limited to 'kittybox-rs/src/indieauth')
-rw-r--r--kittybox-rs/src/indieauth/mod.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/kittybox-rs/src/indieauth/mod.rs b/kittybox-rs/src/indieauth/mod.rs
index f71b5be..cf3278a 100644
--- a/kittybox-rs/src/indieauth/mod.rs
+++ b/kittybox-rs/src/indieauth/mod.rs
@@ -150,12 +150,14 @@ async fn authorization_endpoint_get<A: AuthBackend, D: Storage + 'static>(
     Extension(http): Extension<reqwest::Client>,
     Extension(auth): Extension<A>
 ) -> Response {
-    let me = format!("https://{}/", host).parse().unwrap();
+    let me = format!("https://{host}/").parse().unwrap();
     let h_app = {
+        tracing::debug!("Sending request to {} to fetch metadata", request.client_id);
         match http.get(request.client_id.clone()).send().await {
             Ok(response) => {
                 let url = response.url().clone();
                 let text = response.text().await.unwrap();
+                tracing::debug!("Received {} bytes in response", text.len());
                 match microformats::from_html(&text, url) {
                     Ok(mf2) => {
                         if let Some(relation) = mf2.rels.items.get(&request.redirect_uri) {