Skip to content

Commit

Permalink
Omit pipe in single function call
Browse files Browse the repository at this point in the history
  • Loading branch information
leonqadirie authored and lpil committed Aug 15, 2024
1 parent a680dde commit ab44d10
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,7 @@ pub fn send_request() {
request.to("https://test-api.service.hmrc.gov.uk/hello/world")
let req =
base_req
|> request.prepend_header("accept", "application/vnd.hmrc.1.0+json")
request.prepend_header(base_req, "accept", "application/vnd.hmrc.1.0+json")
// Send the HTTP request to the server
use resp <- result.try(httpc.send(req))
Expand Down

0 comments on commit ab44d10

Please sign in to comment.