aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/auth.rs1
-rw-r--r--src/listing.rs1
-rw-r--r--src/main.rs1
-rw-r--r--src/renderer.rs1
4 files changed, 4 insertions, 0 deletions
diff --git a/src/auth.rs b/src/auth.rs
index 8e6532b..040e81f 100644
--- a/src/auth.rs
+++ b/src/auth.rs
@@ -75,6 +75,7 @@ pub fn match_auth(basic_auth: BasicAuthParams, required_auth: &RequiredAuth) ->
}
/// Return `true` if hashing of `password` by `T` algorithm equals to `hash`
+#[allow(clippy::ptr_arg)]
pub fn compare_hash<T: Digest>(password: String, hash: &Vec<u8>) -> bool {
get_hash::<T>(password) == *hash
}
diff --git a/src/listing.rs b/src/listing.rs
index a030feb..87fd8a8 100644
--- a/src/listing.rs
+++ b/src/listing.rs
@@ -123,6 +123,7 @@ pub fn file_handler(req: &HttpRequest<crate::MiniserveConfig>) -> Result<fs::Nam
/// List a directory and renders a HTML file accordingly
/// Adapted from https://docs.rs/actix-web/0.7.13/src/actix_web/fs.rs.html#564
+#[allow(clippy::identity_conversion)]
pub fn directory_listing<S>(
dir: &fs::Directory,
req: &HttpRequest<S>,
diff --git a/src/main.rs b/src/main.rs
index c1bb0aa..b7563eb 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -65,6 +65,7 @@ fn main() {
}
}
+#[allow(clippy::block_in_if_condition_stmt)]
fn run() -> Result<(), ContextualError> {
if cfg!(windows) && !Paint::enable_windows_ascii() {
Paint::disable();
diff --git a/src/renderer.rs b/src/renderer.rs
index b292e70..69224cf 100644
--- a/src/renderer.rs
+++ b/src/renderer.rs
@@ -9,6 +9,7 @@ use crate::listing::{Entry, SortingMethod, SortingOrder};
use crate::themes::ColorScheme;
/// Renders the file listing
+#[allow(clippy::too_many_arguments)]
pub fn page(
serve_path: &str,
entries: Vec<Entry>,