From a041d4a9855242414babd5a850cc140991ca152d Mon Sep 17 00:00:00 2001 From: BBaoVanC Date: Fri, 17 Jan 2025 03:44:34 -0600 Subject: [PATCH] Fix new clippy::unnecessary_map_or lint --- bobashare/src/storage/upload.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bobashare/src/storage/upload.rs b/bobashare/src/storage/upload.rs index 5750bb2f..d33ce2d9 100644 --- a/bobashare/src/storage/upload.rs +++ b/bobashare/src/storage/upload.rs @@ -27,7 +27,7 @@ impl Upload { pub fn is_expired(&self) -> bool { // if None (never expires) then not expired (false) // otherwise if expiry is before now, then it is expired - self.expiry_date.map_or(false, |e| e < Utc::now()) + self.expiry_date.is_some_and(|e| e < Utc::now()) } }