Skip to content

Commit

Permalink
chore: fix typos (#3248)
Browse files Browse the repository at this point in the history
  • Loading branch information
jayvdb committed Jan 16, 2024
1 parent e442b00 commit 2915bb7
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions actix-web/MIGRATION-4.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -372,13 +372,13 @@ You may need to review the [guidance on shared mutable state](https://docs.rs/ac
HttpServer::new(|| {
- App::new()
- .data(MyState::default())
- .service(hander)
- .service(handler)

+ let my_state: Data<MyState> = Data::new(MyState::default());
+
+ App::new()
+ .app_data(my_state)
+ .service(hander)
+ .service(handler)
})
```

Expand Down
2 changes: 1 addition & 1 deletion actix-web/src/data.rs
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ pub(crate) type FnDataFactory =
/// HttpResponse::Ok()
/// }
///
/// /// Alteratively, use the `HttpRequest::app_data` method to access data in a handler.
/// /// Alternatively, use the `HttpRequest::app_data` method to access data in a handler.
/// async fn index_alt(req: HttpRequest) -> impl Responder {
/// let data = req.app_data::<Data<Mutex<MyData>>>().unwrap();
/// let mut my_data = data.lock().unwrap();
Expand Down
2 changes: 1 addition & 1 deletion actix-web/src/guard/acceptable.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ use crate::http::header::Accept;
pub struct Acceptable {
mime: mime::Mime,

/// Wether to match `*/*` mime type.
/// Whether to match `*/*` mime type.
///
/// Defaults to false because it's not very useful otherwise.
match_star_star: bool,
Expand Down
2 changes: 1 addition & 1 deletion actix-web/src/guard/host.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ use actix_http::{header, uri::Uri, RequestHead};

use super::{Guard, GuardContext};

/// Creates a guard that matches requests targetting a specific host.
/// Creates a guard that matches requests targeting a specific host.
///
/// # Matching Host
/// This guard will:
Expand Down

0 comments on commit 2915bb7

Please sign in to comment.