Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions rusk/src/lib/http/event.rs
Original file line number Diff line number Diff line change
Expand Up @@ -524,8 +524,8 @@ impl Event {
Ok((event, binary_response))
}
}
const CONTENT_TYPE: &str = "Content-Type";
const ACCEPT: &str = "Accept";
const CONTENT_TYPE: &str = "content-type";
const ACCEPT: &str = "accept";
const CONTENT_TYPE_BINARY: &str = "application/octet-stream";
static CONTENT_TYPE_JSON: HeaderValue =
HeaderValue::from_static("application/json");
Expand Down Expand Up @@ -884,7 +884,7 @@ impl RuesDispatchEvent {
pub fn is_binary(&self) -> bool {
self.headers
.get(CONTENT_TYPE)
.map(|h| h.to_string())
.and_then(|h| h.as_str())
.map(|v| v.eq_ignore_ascii_case(CONTENT_TYPE_BINARY))
.unwrap_or_default()
}
Expand Down
Loading