From 6e852c6c603ade6fa3584f09e4b90a28de4f4082 Mon Sep 17 00:00:00 2001
From: Manuel Thalmann <m@nuth.ch>
Date: Thu, 3 Apr 2025 08:22:37 +0200
Subject: [PATCH] Chain asynchronous calls

---
 hello-async/src/main.rs | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/hello-async/src/main.rs b/hello-async/src/main.rs
index 65a171b..6bc2e81 100644
--- a/hello-async/src/main.rs
+++ b/hello-async/src/main.rs
@@ -5,8 +5,7 @@ fn main() {
 }
 
 async fn page_title(url: &str) -> Option<String> {
-    let response = trpl::get(url).await;
-    let response_text = response.text().await;
+    let response_text = trpl::get(url).await.text().await;
     Html::parse(&response_text)
         .select_first("title")
         .map(|title_element| title_element.inner_html())