aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorboastful-squirrel <boastful.squirrel@gmail.com>2019-05-01 15:08:15 +0000
committerboastful-squirrel <boastful.squirrel@gmail.com>2019-05-01 15:08:15 +0000
commit5c5b0c75509364f64c9af48595fc2dc95b0ba849 (patch)
treec42971e90e7e25eaad2ca505bc90496f2a533078 /src
parentDisplay 404 error (diff)
downloadminiserve-5c5b0c75509364f64c9af48595fc2dc95b0ba849.tar.gz
miniserve-5c5b0c75509364f64c9af48595fc2dc95b0ba849.zip
Added doc
Diffstat (limited to '')
-rw-r--r--src/auth.rs3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/auth.rs b/src/auth.rs
index b5a9867..23ea668 100644
--- a/src/auth.rs
+++ b/src/auth.rs
@@ -129,6 +129,9 @@ impl Middleware<crate::MiniserveConfig> for Auth {
}
}
+/// Builds the unauthorized response body
+/// The reason why log_error_chain is optional is to handle cases where the auth pop-up appears and when the user clicks Cancel.
+/// In those case, we do not log the error to the terminal since it does not really matter.
fn build_unauthorized_response(
req: &HttpRequest<crate::MiniserveConfig>,
error: ContextualError,