fix: add newlines

ugly code but without it the output is uglier
This commit is contained in:
əlemi 2024-10-19 05:02:18 +02:00
parent a6576f1947
commit 2f8920eefe
Signed by: alemi
GPG key ID: A4895B84D311642C

View file

@ -152,13 +152,14 @@ impl Endpoint {
StringOr::Str(_query) => todo!(),
StringOr::T(Extractor::Discard) => "".to_string(),
StringOr::T(Extractor::Debug) => format!("{res:#?}\n"),
StringOr::T(Extractor::Body) => res.text().await?,
StringOr::T(Extractor::Body) => res.text().await? + "\n",
StringOr::T(Extractor::Header { key }) => res
.headers()
.get(&key)
.ok_or(PostWomanError::HeaderNotFound(key))?
.to_str()?
.to_string(),
.to_string()
+ "\n",
})
}
}