From 0c61dca9cadc81e759c6da984e94a2eb15d8e368 Mon Sep 17 00:00:00 2001 From: Kitaiti Makoto Date: Sat, 23 Apr 2022 22:49:13 +0900 Subject: [PATCH] Follow clippy --- plume-models/src/posts.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/plume-models/src/posts.rs b/plume-models/src/posts.rs index 2590760f..f112b098 100644 --- a/plume-models/src/posts.rs +++ b/plume-models/src/posts.rs @@ -1145,7 +1145,7 @@ impl FromId07 for Post { .summary() .and_then(|summary| summary.to_as_string()) .ok_or(Error::MissingApProperty)?, - source: source, + source, cover_id: cover, }, ) @@ -1180,11 +1180,11 @@ impl FromId07 for Post { tag.clone() .extend::() // FIXME: Don't clone - .and_then(|hashtag| { - Ok(hashtag.and_then(|t| { + .map(|hashtag| { + hashtag.and_then(|t| { let tag_name = t.name.clone()?.as_str().to_string(); Tag::from_activity07(conn, &t, post.id, hashtags.remove(&tag_name)).ok() - })) + }) }) .ok(); }