Skip to content

Commit

Permalink
solved clippy compilation error
Browse files Browse the repository at this point in the history
  • Loading branch information
Hidden-Revolver committed Sep 1, 2024
1 parent 6d406f6 commit 1c04963
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ impl HttpServer {
let mut line_str = String::new();
let bytes_read = buf_reader.read_line(&mut line_str)?;

request_bytes.write(line_str.as_bytes())?;
let _ = request_bytes.write(line_str.as_bytes());

if body_size == 0 && line_str.to_lowercase().contains("content-length") {
let mut parts = line_str.split(':');
Expand All @@ -153,7 +153,7 @@ impl HttpServer {
let mut body_bytes_buffer = vec![0; body_size];
buf_reader.read_exact(&mut body_bytes_buffer)?;

request_bytes.write(&body_bytes_buffer)?;
let _ = request_bytes.write(&body_bytes_buffer);

let request = request::Request::try_from(request_bytes)?;

Expand Down

0 comments on commit 1c04963

Please sign in to comment.