Skip to content

Commit

Permalink
run clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
magiclen committed Mar 11, 2021
1 parent bb470fc commit 5eccb0f
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 6 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "rocket-include-static-resources"
version = "0.9.5"
version = "0.9.6"
authors = ["Magic Len <len@magiclen.org>"]
edition = "2018"
repository = "https://github.com/magiclen/rocket-include-static-resources"
Expand Down
5 changes: 1 addition & 4 deletions src/file_resources.rs
Expand Up @@ -53,10 +53,7 @@ impl FileResources {
pub fn unregister_resource_file<S: AsRef<str>>(&mut self, name: S) -> Option<PathBuf> {
let name = name.as_ref();

match self.resources.remove(name) {
Some((file_path, _, _, _, _)) => Some(file_path),
None => None,
}
self.resources.remove(name).map(|(file_path, _, _, _, _)| file_path)
}

#[inline]
Expand Down
2 changes: 1 addition & 1 deletion src/lib.rs
Expand Up @@ -156,7 +156,7 @@ impl<'a> Responder<'a> for StaticResponse {

return response.ok();
} else {
(mime.to_string(), data.clone(), etag.to_string())
(mime.to_string(), data, etag.to_string())
}
}
Err(_) => {
Expand Down

0 comments on commit 5eccb0f

Please sign in to comment.