1
Fork 0

nodeinfo: Use header names from reqwest::header

This commit is contained in:
Steffo 2024-11-09 14:17:51 +01:00
parent 707d6d3d54
commit de5fdf26f3
Signed by: steffo
GPG key ID: 5ADA3868646C3FC0

View file

@ -63,7 +63,7 @@ impl HostMetaDocument {
log::trace!("Checking headers of the response..."); log::trace!("Checking headers of the response...");
response response
.headers() .headers()
.get("Content-Type") .get(reqwest::header::CONTENT_TYPE)
.ok_or(ContentTypeMissing)? .ok_or(ContentTypeMissing)?
.eq("application/json") .eq("application/json")
.then_some(()) .then_some(())
@ -110,7 +110,7 @@ impl HostMetaDocument {
log::trace!("Checking headers of the response..."); log::trace!("Checking headers of the response...");
response response
.headers() .headers()
.get("Content-Type") .get(reqwest::header::CONTENT_TYPE)
.ok_or(ContentTypeMissing)? .ok_or(ContentTypeMissing)?
.eq("application/xrd+json") .eq("application/xrd+json")
.then_some(()) .then_some(())