Skip to content

Commit

Permalink
Fix clippy warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
billy1624 committed Aug 25, 2022
1 parent 1da417d commit 0fa62c9
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions sea-orm-codegen/src/entity/base_entity.rs
Original file line number Diff line number Diff line change
Expand Up @@ -152,9 +152,11 @@ impl Entity {
pub fn get_eq_needed(&self) -> TokenStream {
self.columns
.iter()
.find(|column| match column.col_type {
ColumnType::Float(_) | ColumnType::Double(_) => true,
_ => false,
.find(|column| {
matches!(
column.col_type,
ColumnType::Float(_) | ColumnType::Double(_)
)
})
// check if float or double exist.
// if exist, return nothing
Expand Down

0 comments on commit 0fa62c9

Please sign in to comment.