Skip to content

Commit

Permalink
Clippy fixes for 1.78.
Browse files Browse the repository at this point in the history
  • Loading branch information
LaurentMazare committed May 3, 2024
1 parent 37d90c3 commit f4a4eef
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions examples/yolo/darknet.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ struct Block {

impl Block {
fn get(&self, key: &str) -> Result<&str> {
match self.parameters.get(&key.to_string()) {
match self.parameters.get(key) {
None => bail!("cannot find {} in {}", key, self.block_type),
Some(value) => Ok(value),
}
Expand All @@ -32,7 +32,7 @@ pub struct Darknet {

impl Darknet {
fn get(&self, key: &str) -> Result<&str> {
match self.parameters.get(&key.to_string()) {
match self.parameters.get(key) {
None => bail!("cannot find {} in net parameters", key),
Some(value) => Ok(value),
}
Expand Down

0 comments on commit f4a4eef

Please sign in to comment.