Skip to content

Commit

Permalink
Updated documentation in examples (#1219)
Browse files Browse the repository at this point in the history
Documentation in examples recommends using
`tokio 0.2` as dependency, while README.md
recomends `tokio 0.1`.
I've updated comments according to readme.
  • Loading branch information
kotborealis committed Mar 22, 2021
1 parent dada01e commit 29b15cb
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 4 deletions.
3 changes: 3 additions & 0 deletions examples/form.rs
@@ -1,5 +1,8 @@
// Short example of a POST request with form data.
//
// This is using the `tokio` runtime. You'll need the following dependency:
//
// `tokio = { version = "1", features = ["full"] }`
#[cfg(not(target_arch = "wasm32"))]
#[tokio::main]
async fn main() {
Expand Down
2 changes: 1 addition & 1 deletion examples/json_dynamic.rs
Expand Up @@ -6,7 +6,7 @@

// This is using the `tokio` runtime. You'll need the following dependency:
//
// `tokio = { version = "0.2", features = ["macros"] }`
// `tokio = { version = "1", features = ["full"] }`
#[tokio::main]
async fn main() -> Result<(), reqwest::Error> {
let echo_json: serde_json::Value = reqwest::Client::new()
Expand Down
2 changes: 1 addition & 1 deletion examples/json_typed.rs
Expand Up @@ -18,7 +18,7 @@ struct Post {

// This is using the `tokio` runtime. You'll need the following dependency:
//
// `tokio = { version = "0.2", features = ["macros"] }`
// `tokio = { version = "1", features = ["full"] }`
#[tokio::main]
async fn main() -> Result<(), reqwest::Error> {
let new_post = Post {
Expand Down
2 changes: 1 addition & 1 deletion examples/simple.rs
Expand Up @@ -2,7 +2,7 @@

// This is using the `tokio` runtime. You'll need the following dependency:
//
// `tokio = { version = "0.2", features = ["macros"] }`
// `tokio = { version = "1", features = ["full"] }`
#[cfg(not(target_arch = "wasm32"))]
#[tokio::main]
async fn main() -> Result<(), reqwest::Error> {
Expand Down
2 changes: 1 addition & 1 deletion examples/tor_socks.rs
Expand Up @@ -2,7 +2,7 @@

// This is using the `tokio` runtime. You'll need the following dependency:
//
// `tokio = { version = "0.2", features = ["macros"] }`
// `tokio = { version = "1", features = ["full"] }`
#[tokio::main]
async fn main() -> Result<(), reqwest::Error> {
// Make sure you are running tor and this is your socks port
Expand Down

0 comments on commit 29b15cb

Please sign in to comment.