Skip to content

Commit

Permalink
Fixed clippy warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
buj committed Sep 7, 2024
1 parent 346e9e6 commit eccf10e
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 10 deletions.
9 changes: 0 additions & 9 deletions src/hook.rs
Original file line number Diff line number Diff line change
Expand Up @@ -64,15 +64,6 @@ impl Message {
std::thread::sleep(Duration::from_secs(10));
}
}

pub fn reply<L: Logger>(
&self,
hook: &Webhook,
message: impl Fn(MessageBuilder) -> MessageBuilder,
logger: &mut L,
) -> Message {
hook.send(message, logger)
}
}

struct ApiMessage {
Expand Down
4 changes: 3 additions & 1 deletion src/upload.rs
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,9 @@ pub fn upload<'a, L: Logger>(config: &'a Config, log: &'a mut L) {

head.edit(&config.webhook, "Publishing artifact...", log);

let delete_file = |x: &mut PathBuf| drop(fs::remove_file(x).ok());
let delete_file = |x: &mut PathBuf| {
let _ = fs::remove_file(x).ok();
};

let mut script_path = Defer::new(temp_path(), delete_file);
let mut script_file = Rc::new(Mutex::new(
Expand Down

0 comments on commit eccf10e

Please sign in to comment.