From 097fbd7df0fbe376b3570f460377358645ca921f Mon Sep 17 00:00:00 2001 From: Jeb Rosen Date: Sun, 31 May 2020 11:31:57 -0700 Subject: [PATCH] Fix some broken links in API documentation. --- contrib/lib/src/compression/mod.rs | 3 +-- contrib/lib/src/databases.rs | 1 - contrib/lib/src/json.rs | 2 +- contrib/lib/src/serve.rs | 2 +- contrib/lib/src/templates/mod.rs | 4 ---- core/http/src/accept.rs | 2 +- core/lib/src/config/mod.rs | 4 ++-- core/lib/src/fairing/mod.rs | 4 ++-- core/lib/src/local/mod.rs | 5 +---- core/lib/src/outcome.rs | 2 +- core/lib/src/response/redirect.rs | 2 +- 11 files changed, 11 insertions(+), 20 deletions(-) diff --git a/contrib/lib/src/compression/mod.rs b/contrib/lib/src/compression/mod.rs index 4655407b..8ba9f3d5 100644 --- a/contrib/lib/src/compression/mod.rs +++ b/contrib/lib/src/compression/mod.rs @@ -1,7 +1,6 @@ //! Gzip and Brotli response compression. //! -//! See the [`Compression`](compression::Compression) and -//! [`Compress`](compression::Compress) types for further details. +//! See the [`Compression`] and [`Compress`] types for further details. //! //! # Enabling //! diff --git a/contrib/lib/src/databases.rs b/contrib/lib/src/databases.rs index 46566e84..33e3560d 100644 --- a/contrib/lib/src/databases.rs +++ b/contrib/lib/src/databases.rs @@ -394,7 +394,6 @@ //! //! [`FromRequest`]: rocket::request::FromRequest //! [request guards]: rocket::request::FromRequest -//! [`Poolable`]: databases::Poolable pub extern crate r2d2; diff --git a/contrib/lib/src/json.rs b/contrib/lib/src/json.rs index a59948ca..d0827556 100644 --- a/contrib/lib/src/json.rs +++ b/contrib/lib/src/json.rs @@ -1,6 +1,6 @@ //! Automatic JSON (de)serialization support. //! -//! See the [`Json`](json::Json) type for further details. +//! See the [`Json`] type for further details. //! //! # Enabling //! diff --git a/contrib/lib/src/serve.rs b/contrib/lib/src/serve.rs index 8f32069f..7cbf8de7 100644 --- a/contrib/lib/src/serve.rs +++ b/contrib/lib/src/serve.rs @@ -1,6 +1,6 @@ //! Custom handler and options for static file serving. //! -//! See the [`StaticFiles`](serve::StaticFiles) type for further details. +//! See the [`StaticFiles`] type for further details. //! //! # Enabling //! diff --git a/contrib/lib/src/templates/mod.rs b/contrib/lib/src/templates/mod.rs index 9c22cb54..9d3dbb4a 100644 --- a/contrib/lib/src/templates/mod.rs +++ b/contrib/lib/src/templates/mod.rs @@ -111,10 +111,6 @@ //! template reloading is disabled to improve performance and cannot be enabled. //! //! [`Serialize`]: serde::Serialize -//! [`Template`]: templates::Template -//! [`Template::fairing()`]: templates::Template::fairing() -//! [`Template::custom()`]: templates::Template::custom() -//! [`Template::render()`]: templates::Template::render() #[cfg(feature = "tera_templates")] pub extern crate tera; #[cfg(feature = "tera_templates")] mod tera_templates; diff --git a/core/http/src/accept.rs b/core/http/src/accept.rs index ff3762ac..e56484fa 100644 --- a/core/http/src/accept.rs +++ b/core/http/src/accept.rs @@ -130,7 +130,7 @@ impl PartialEq for AcceptParams { /// [`Request::accept()`] method. The [`preferred()`] method can be used to /// retrieve the client's preferred media type. /// -/// [`Request::accept`]: rocket::Request::accept() +/// [`Request::accept()`]: rocket::Request::accept() /// [`preferred()`]: Accept::preferred() /// /// An `Accept` type with a single, common media type can be easily constructed diff --git a/core/lib/src/config/mod.rs b/core/lib/src/config/mod.rs index c69b48d7..8e2ff04f 100644 --- a/core/lib/src/config/mod.rs +++ b/core/lib/src/config/mod.rs @@ -154,8 +154,8 @@ //! ## Retrieving Configuration Parameters //! //! Configuration parameters for the currently active configuration environment -//! can be retrieved via the [`Rocket::config()`] `Rocket` and `get_` methods on -//! [`Config`] structure. +//! can be retrieved via the [`Rocket::config()`](crate::Rocket::config()) method +//! on `Rocket` and `get_` methods on [`Config`] structure. //! //! The retrivial of configuration parameters usually occurs at launch time via //! a [launch fairing](crate::fairing::Fairing). If information about the diff --git a/core/lib/src/fairing/mod.rs b/core/lib/src/fairing/mod.rs index fec4e86e..12dd2a4d 100644 --- a/core/lib/src/fairing/mod.rs +++ b/core/lib/src/fairing/mod.rs @@ -8,8 +8,8 @@ //! to perform an action once a Rocket application has launched. //! //! To learn more about writing a fairing, see the [`Fairing`] trait -//! documentation. You can also use [`AdHoc`](fairing::AdHoc) to create a -//! fairing on-the-fly from a closure or function. +//! documentation. You can also use [`AdHoc`] to create a fairing on-the-fly +//! from a closure or function. //! //! ## Attaching //! diff --git a/core/lib/src/local/mod.rs b/core/lib/src/local/mod.rs index 6265718a..676f8680 100644 --- a/core/lib/src/local/mod.rs +++ b/core/lib/src/local/mod.rs @@ -9,7 +9,7 @@ //! //! This module contains a [`Client`] structure that is used to create //! [`LocalRequest`] structures that can be dispatched against a given -//! [`Rocket`] instance. Usage is straightforward: +//! [`Rocket`](crate::Rocket) instance. Usage is straightforward: //! //! 1. Construct a `Rocket` instance that represents the application. //! @@ -94,9 +94,6 @@ //! } //! } //! ``` -//! -//! [`Client`]: local::Client -//! [`LocalRequest`]: local::LocalRequest mod request; mod client; diff --git a/core/lib/src/outcome.rs b/core/lib/src/outcome.rs index 5d0332c9..72a6392f 100644 --- a/core/lib/src/outcome.rs +++ b/core/lib/src/outcome.rs @@ -12,7 +12,7 @@ //! including [`FromRequest`](crate::request::FromRequest), //! [`FromData`](crate::data::FromData), and //! [`Responder`](crate::response::Responder). It is also the return type of -//! request handlers via the [`Response`] type. +//! request handlers via the [`Response`](crate::response::Response) type. //! //! # Success //! diff --git a/core/lib/src/response/redirect.rs b/core/lib/src/response/redirect.rs index bfecf274..0d478bcd 100644 --- a/core/lib/src/response/redirect.rs +++ b/core/lib/src/response/redirect.rs @@ -41,7 +41,7 @@ use crate::http::Status; /// } /// ``` /// -/// [`Origin`]: crate::::http::uri::Origin +/// [`Origin`]: crate::http::uri::Origin /// [`uri!`]: ../macro.uri.html #[derive(Debug)] pub struct Redirect(Status, Option>);