Skip to content

Commit

Permalink
docs(example): change suggestion in echo.rs for windows compat (hyper…
Browse files Browse the repository at this point in the history
…ium#3220)

The suggested curl statement should work for all users out-of-the-box.

Regression tested against windows, macos, and linux (dev container).
  • Loading branch information
IsaacCloos authored and 0xE282B0 committed Jan 12, 2024
1 parent 7216efe commit b1e4a36
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/echo.rs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ async fn echo(
match (req.method(), req.uri().path()) {
// Serve some instructions at /
(&Method::GET, "/") => Ok(Response::new(full(
"Try POSTing data to /echo such as: `curl localhost:3000/echo -XPOST -d 'hello world'`",
"Try POSTing data to /echo such as: `curl localhost:3000/echo -XPOST -d \"hello world\"`",
))),

// Simply echo the body back to the client.
Expand Down

0 comments on commit b1e4a36

Please sign in to comment.