From 8e8dfc7d45cd1276a4feeefd1d53f03669c5a057 Mon Sep 17 00:00:00 2001 From: Sergio Benitez Date: Sun, 17 Jul 2022 18:45:11 -0700 Subject: [PATCH] Clarify built-in request guard implementations. --- core/lib/src/request/from_request.rs | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/core/lib/src/request/from_request.rs b/core/lib/src/request/from_request.rs index 43ca1092..c164303c 100644 --- a/core/lib/src/request/from_request.rs +++ b/core/lib/src/request/from_request.rs @@ -159,20 +159,21 @@ impl IntoOutcome for Result { /// /// * **ContentType** /// -/// Extracts the [`ContentType`] from the incoming request. If the request -/// didn't specify a Content-Type, the request is forwarded. +/// Extracts the [`ContentType`] from the incoming request via +/// [`Request::content_type()`]. If the request didn't specify a +/// Content-Type, the request is forwarded. /// /// * **IpAddr** /// -/// Extracts the client ip address of the incoming request as an [`IpAddr`]. -/// If the client's IP address is not known, the request is forwarded. +/// Extracts the client ip address of the incoming request as an [`IpAddr`] +/// via [`Request::client_ip()`]. If the client's IP address is not known, +/// the request is forwarded. /// /// * **SocketAddr** /// -/// Extracts the remote address of the incoming request as a [`SocketAddr`]. -/// If the remote address is not known, the request is forwarded. -/// -/// _This implementation always returns successfully._ +/// Extracts the remote address of the incoming request as a [`SocketAddr`] +/// via [`Request::remote()`]. If the remote address is not known, the +/// request is forwarded. /// /// * **Option<T>** _where_ **T: FromRequest** ///