Skip to content

Commit

Permalink
docs(*): fix typos, Markdown inconsistencies, and stutter
Browse files Browse the repository at this point in the history
  • Loading branch information
justinmayhew committed May 20, 2016
1 parent 54a9a7d commit 8f1c536
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 9 deletions.
5 changes: 2 additions & 3 deletions src/header/common/prefer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,8 @@ use header::parsing::{from_comma_delimited, fmt_comma_delimited};

/// `Prefer` header, defined in [RFC7240](http://tools.ietf.org/html/rfc7240)
///
/// The `Prefer` header field is HTTP header field that can be used by a
/// client to request that certain behaviors be employed by a server
/// while processing a request.
/// The `Prefer` header field can be used by a client to request that certain
/// behaviors be employed by a server while processing a request.
///
/// # ABNF
/// ```plain
Expand Down
2 changes: 1 addition & 1 deletion src/method.rs
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ impl Method {
}

/// Whether a method is considered "idempotent", meaning the request has
/// the same result is executed multiple times.
/// the same result if executed multiple times.
///
/// See [the spec](https://tools.ietf.org/html/rfc7231#section-4.2.2) for
/// more words.
Expand Down
8 changes: 4 additions & 4 deletions src/net.rs
Original file line number Diff line number Diff line change
Expand Up @@ -179,15 +179,15 @@ pub trait Ssl {
fn wrap_server(&self, stream: HttpStream) -> ::Result<Self::Stream>;
}

/// An abstraction to allow any SSL implementation to be used with client-side HttpsStreams.
/// An abstraction to allow any SSL implementation to be used with client-side `HttpsStream`s.
pub trait SslClient {
/// The protected stream.
type Stream: Transport;
/// Wrap a client stream with SSL.
fn wrap_client(&self, stream: HttpStream, host: &str) -> ::Result<Self::Stream>;
}

/// An abstraction to allow any SSL implementation to be used with server-side HttpsStreams.
/// An abstraction to allow any SSL implementation to be used with server-side `HttpsStream`s.
pub trait SslServer {
/// The protected stream.
type Stream: Transport;
Expand Down Expand Up @@ -323,7 +323,7 @@ impl<S: Transport> Transport for HttpsStream<S> {
}
}

/// A Http Listener over SSL.
/// An `HttpListener` over SSL.
#[derive(Debug)]
pub struct HttpsListener<S: SslServer> {
listener: TcpListener,
Expand All @@ -340,7 +340,7 @@ impl<S: SslServer> HttpsListener<S> {
})
}

/// Construct an HttpsListener from a bound `TcpListener`.
/// Construct an `HttpsListener` from a bound `TcpListener`.
pub fn with_listener(listener: TcpListener, ssl: S) -> HttpsListener<S> {
HttpsListener {
listener: listener,
Expand Down
2 changes: 1 addition & 1 deletion src/server/mod.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//! HTTP Server
//!
//! A `Server` is created to listen on port, parse HTTP requests, and hand
//! A `Server` is created to listen on a port, parse HTTP requests, and hand
//! them off to a `Handler`.
use std::fmt;
use std::net::SocketAddr;
Expand Down

0 comments on commit 8f1c536

Please sign in to comment.