diff --git a/contrib/lib/src/helmet/policy.rs b/contrib/lib/src/helmet/policy.rs index 4ce6dace..bae15009 100644 --- a/contrib/lib/src/helmet/policy.rs +++ b/contrib/lib/src/helmet/policy.rs @@ -135,7 +135,7 @@ pub enum Referrer { StrictOrigin, /// Send full URL for same-origin requests. For cross-origin requests, only - /// send origin part of URL if protocl security level remains the same e.g. + /// send origin part of URL if protocol security level remains the same e.g. /// HTTPS to HTTPS. StrictOriginWhenCrossOrigin, diff --git a/contrib/lib/src/templates/metadata.rs b/contrib/lib/src/templates/metadata.rs index 0d1c386f..5cd5e909 100644 --- a/contrib/lib/src/templates/metadata.rs +++ b/contrib/lib/src/templates/metadata.rs @@ -4,7 +4,7 @@ use rocket::request::{self, FromRequest}; use crate::templates::ContextManager; -/// Request guard for dynamiclly querying template metadata. +/// Request guard for dynamically querying template metadata. /// /// # Usage /// diff --git a/core/codegen/src/bang/uri.rs b/core/codegen/src/bang/uri.rs index f7fe7d83..e6bce960 100644 --- a/core/codegen/src/bang/uri.rs +++ b/core/codegen/src/bang/uri.rs @@ -199,7 +199,7 @@ fn explode_query<'a, I: Iterator>( Some(quote!(#uri_mod::UriArgumentsKind::Dynamic(&[#(#dyn_exprs),*]))) } -// Returns an Origin URI with the mount point and route path concatinated. The +// Returns an Origin URI with the mount point and route path concatenated. The // query string is mangled by replacing single dynamic parameters in query parts // (``) with `param=`. fn build_origin(internal: &InternalUriParams) -> Origin<'static> { diff --git a/core/codegen/src/lib.rs b/core/codegen/src/lib.rs index e1f624d6..8751c3a2 100644 --- a/core/codegen/src/lib.rs +++ b/core/codegen/src/lib.rs @@ -652,7 +652,7 @@ pub fn derive_from_form(input: TokenStream) -> TokenStream { /// The attribute accepts two key/value pairs: `status` and `content_type`. The /// value of `status` must be an unsigned integer representing a valid status /// code. The [`Response`] produced from the generated implementation will have -/// its status overriden to this value. +/// its status overridden to this value. /// /// The value of `content_type` must be a valid media-type in `top/sub` form or /// `shorthand` form. Examples include: @@ -666,7 +666,7 @@ pub fn derive_from_form(input: TokenStream) -> TokenStream { /// /// See [`ContentType::parse_flexible()`] for a full list of available /// shorthands. The [`Response`] produced from the generated implementation will -/// have its content-type overriden to this value. +/// have its content-type overridden to this value. /// /// [`Responder`]: ../rocket/response/trait.Responder.html /// [`Response`]: ../rocket/struct.Response.html @@ -703,7 +703,7 @@ pub fn derive_responder(input: TokenStream) -> TokenStream { /// /// The derive generates an implementation of the [`UriDisplay`] trait. /// The implementation calls [`Formatter::write_named_value()`] for every named -/// field, using the field's name (unless overriden, explained next) as the +/// field, using the field's name (unless overridden, explained next) as the /// `name` parameter, and [`Formatter::write_value()`] for every unnamed field /// in the order the fields are declared. /// diff --git a/core/codegen/tests/route.rs b/core/codegen/tests/route.rs index ff0aeeaf..0ed896ce 100644 --- a/core/codegen/tests/route.rs +++ b/core/codegen/tests/route.rs @@ -15,7 +15,7 @@ use rocket::request::Form; use rocket::http::{Status, RawStr, ContentType}; use rocket::tokio::io::AsyncReadExt; -// Use all of the code generation avaiable at once. +// Use all of the code generation available at once. #[derive(FromForm, UriDisplayQuery)] struct Inner<'r> { diff --git a/core/http/src/parse/uri/error.rs b/core/http/src/parse/uri/error.rs index 08e34b59..4ed386cf 100644 --- a/core/http/src/parse/uri/error.rs +++ b/core/http/src/parse/uri/error.rs @@ -9,7 +9,7 @@ use crate::ext::IntoOwned; /// Error emitted on URI parse failure. /// /// Internally, the type includes information about where the parse error -/// occured (the error's context) and information about what went wrong. +/// occurred (the error's context) and information about what went wrong. /// Externally, this information can be retrieved (in textual form) through its /// `Display` implementation. In other words, by printing a value of this type. #[derive(Debug)] diff --git a/core/http/src/uri/formatter.rs b/core/http/src/uri/formatter.rs index 77f1a20f..2eee6837 100644 --- a/core/http/src/uri/formatter.rs +++ b/core/http/src/uri/formatter.rs @@ -26,7 +26,7 @@ use crate::uri::{UriPart, Path, Query, UriDisplay, Origin}; /// struct properly formats series of values for use in URIs. In particular, /// this struct applies the following transformations: /// -/// * When **mutliple values** are written, they are separated by `/` for +/// * When **multiple values** are written, they are separated by `/` for /// `Path` types and `&` for `Query` types. /// /// Additionally, for `Formatter`: diff --git a/core/lib/src/config/error.rs b/core/lib/src/config/error.rs index 678d3401..8849447d 100644 --- a/core/lib/src/config/error.rs +++ b/core/lib/src/config/error.rs @@ -165,7 +165,7 @@ impl Error for ConfigError { NotFound => "config file was not found", IoError => "there was an I/O error while reading the config file", RandFailure => "randomness could not be retrieved from the OS", - Io(..) => "an I/O error occured while setting a configuration parameter", + Io(..) => "an I/O error occurred while setting a configuration parameter", BadFilePath(..) => "the config file path is invalid", BadEntry(..) => "an environment specified as `[environment]` is invalid", BadEnv(..) => "the environment specified in `ROCKET_ENV` is invalid", diff --git a/core/lib/src/config/mod.rs b/core/lib/src/config/mod.rs index c08dae5b..b85b6be4 100644 --- a/core/lib/src/config/mod.rs +++ b/core/lib/src/config/mod.rs @@ -161,7 +161,7 @@ //! //! The retrivial of configuration parameters usually occurs at launch time via //! a [launch fairing](crate::fairing::Fairing). If information about the -//! configuraiton is needed later in the program, an attach fairing can be used +//! configuration is needed later in the program, an attach fairing can be used //! to store the information as managed state. As an example of the latter, //! consider the following short program which reads the `token` configuration //! parameter and stores the value or a default in a `Token` managed state diff --git a/core/lib/src/local/asynchronous/client.rs b/core/lib/src/local/asynchronous/client.rs index 72e01010..42873dc4 100644 --- a/core/lib/src/local/asynchronous/client.rs +++ b/core/lib/src/local/asynchronous/client.rs @@ -12,7 +12,7 @@ use crate::error::LaunchError; /// For the `blocking` version, see /// [`blocking::Client`](crate::local::blocking::Client). /// -/// ## Multithreaded Syncronization Pitfalls +/// ## Multithreaded Synchronization Pitfalls /// /// Unlike its [`blocking`](crate::local::blocking) variant, this `async` `Client` /// implements `Sync`. However, using it in a multithreaded environment while diff --git a/core/lib/src/local/asynchronous/response.rs b/core/lib/src/local/asynchronous/response.rs index c23a841d..ab66e8b0 100644 --- a/core/lib/src/local/asynchronous/response.rs +++ b/core/lib/src/local/asynchronous/response.rs @@ -75,7 +75,7 @@ impl<'c> LocalResponse<'c> { // We have no methods that return an `&Request`. However, we must // also ensure that `Response` doesn't leak any such references. To // do so, we don't expose the `Response` directly in any way; - // otherwise, methods like `.headers()` could, in conjuction with + // otherwise, methods like `.headers()` could, in conjunction with // particular crafted `Responder`s, potentially be used to obtain a // reference to contents of `Request`. All methods, instead, return // references bounded by `self`. This is easily verified by nothing diff --git a/core/lib/src/request/query.rs b/core/lib/src/request/query.rs index c1b95a02..611bf5c7 100644 --- a/core/lib/src/request/query.rs +++ b/core/lib/src/request/query.rs @@ -150,7 +150,7 @@ impl<'q> Iterator for Query<'q> { /// `FromForm` (as in the previous example) will suffice. For special cases /// however, an implementation of `FromQuery` may be warranted. /// -/// Consider a contrived scheme where we expect to recieve one query key, `key`, +/// Consider a contrived scheme where we expect to receive one query key, `key`, /// three times and wish to take the middle value. For instance, consider the /// query: /// diff --git a/core/lib/src/shutdown.rs b/core/lib/src/shutdown.rs index 5c8d1129..2c2e75b0 100644 --- a/core/lib/src/shutdown.rs +++ b/core/lib/src/shutdown.rs @@ -30,7 +30,7 @@ use tokio::sync::mpsc; /// .launch() /// .await; /// -/// // If the server shut down (by visting `/shutdown`), `result` is `Ok`. +/// // If the server shut down (by visiting `/shutdown`), `result` is `Ok`. /// result.expect("server failed unexpectedly"); /// } /// ``` diff --git a/examples/pastebin/src/main.rs b/examples/pastebin/src/main.rs index 34e95597..7e27b894 100644 --- a/examples/pastebin/src/main.rs +++ b/examples/pastebin/src/main.rs @@ -40,7 +40,7 @@ fn index() -> &'static str { accepts raw data in the body of the request and responds with a URL of a page containing the body's content - EXMAPLE: curl --data-binary @file.txt http://localhost:8000 + EXAMPLE: curl --data-binary @file.txt http://localhost:8000 GET / diff --git a/scripts/publish.sh b/scripts/publish.sh index 4b08cd40..1f10421d 100755 --- a/scripts/publish.sh +++ b/scripts/publish.sh @@ -18,7 +18,7 @@ function restore_dev_dependencies() { } if ! [ -z "$(git status --porcelain)" ]; then - echo "There are uncommited changes! Aborting." + echo "There are uncommitted changes! Aborting." exit 1 fi diff --git a/site/guide/10-pastebin.md b/site/guide/10-pastebin.md index 98a9c40f..f49a1638 100644 --- a/site/guide/10-pastebin.md +++ b/site/guide/10-pastebin.md @@ -297,7 +297,7 @@ with the correct ID: # in the project root cargo run -# in a seperate terminal +# in a separate terminal echo "Hello, world." | curl --data-binary @- http://localhost:8000 # => http://localhost:8000/eGs diff --git a/site/news/2018-12-08-version-0.4.md b/site/news/2018-12-08-version-0.4.md index cb348dca..db69dbcd 100644 --- a/site/news/2018-12-08-version-0.4.md +++ b/site/news/2018-12-08-version-0.4.md @@ -403,7 +403,7 @@ This release includes many breaking changes. Please see the for a complete list of breaking changes along with details on handling the breaking change in existing applications. -Rocket 0.3 will continue as a security maintance release _only_. All users are +Rocket 0.3 will continue as a security maintenance release _only_. All users are encouraged to migrate their applications to 0.4. ## General Improvements