Skip to content

Commit

Permalink
Fix clippy warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
threecgreen committed Jun 20, 2022
1 parent 5afff72 commit 297d115
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion src/cached_static.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ use std::fs::{self, File};
use std::io;
use std::path::{Path, PathBuf};

#[derive(Debug, Clone, PartialEq)]
#[derive(Debug, Clone, PartialEq, Eq)]
pub struct NotModified<R>(pub R);

/// Sets the status code of the response to 304 Not Modified.
Expand Down
1 change: 1 addition & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
#![feature(decl_macro, proc_macro_hygiene)]
#![allow(clippy::extra_unused_lifetimes)]

#[macro_use]
extern crate diesel;
Expand Down
4 changes: 2 additions & 2 deletions src/wines/image.rs
Original file line number Diff line number Diff line change
Expand Up @@ -160,8 +160,8 @@ fn handle_exif(
let orientation_field = exif.get_field(exif::Tag::Orientation, exif::In::PRIMARY);
if let Some(orientation_field) = orientation_field {
let orientation = match &orientation_field.value {
exif::Value::Short(v) => v.get(0).map(|n| n.to_owned()),
exif::Value::Byte(v) => v.get(0).map(|n| n.to_owned() as u16),
exif::Value::Short(v) => v.first().map(|n| n.to_owned()),
exif::Value::Byte(v) => v.first().map(|n| n.to_owned() as u16),
_ => None,
};
if let Some(orientation) = orientation {
Expand Down

0 comments on commit 297d115

Please sign in to comment.