nodeinfo
: Report error if MIME type check fails
This commit is contained in:
parent
3cfc86a8fd
commit
c12b0a7869
1 changed files with 2 additions and 1 deletions
|
@ -139,8 +139,9 @@ impl HostMetaDocument {
|
|||
let mime_type = extract_mime_from_content_type(content_type)
|
||||
.ok_or(ContentTypeInvalid)?;
|
||||
|
||||
log::trace!("Ensuring MIME type of `{mime_type}` is acceptable for JRD parsing...");
|
||||
log::trace!("Ensuring MIME type is acceptable for XRD parsing...");
|
||||
if mime_type != "application/xrd+xml" {
|
||||
log::error!("MIME type `{mime_type}` is not acceptable for XRD parsing.");
|
||||
return Err(ContentTypeInvalid)
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue