Fixing some clippy warnings.
This commit is contained in:
parent
8e1f41f1e4
commit
e25436576a
4 changed files with 5 additions and 5 deletions
|
@ -179,7 +179,7 @@ pub(crate) async fn community_receive_message(
|
||||||
.await?;
|
.await?;
|
||||||
}
|
}
|
||||||
|
|
||||||
return Ok(HttpResponse::Ok().finish());
|
Ok(HttpResponse::Ok().finish())
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Handle a follow request from a remote user, adding the user as follower and returning an
|
/// Handle a follow request from a remote user, adding the user as follower and returning an
|
||||||
|
|
|
@ -350,7 +350,7 @@ async fn find_post_or_comment_by_id(
|
||||||
return Ok(PostOrComment::Comment(c));
|
return Ok(PostOrComment::Comment(c));
|
||||||
}
|
}
|
||||||
|
|
||||||
return Err(NotFound.into());
|
Err(NotFound.into())
|
||||||
}
|
}
|
||||||
|
|
||||||
async fn fetch_post_or_comment_by_id(
|
async fn fetch_post_or_comment_by_id(
|
||||||
|
@ -366,7 +366,7 @@ async fn fetch_post_or_comment_by_id(
|
||||||
return Ok(PostOrComment::Comment(comment));
|
return Ok(PostOrComment::Comment(comment));
|
||||||
}
|
}
|
||||||
|
|
||||||
return Err(NotFound.into());
|
Err(NotFound.into())
|
||||||
}
|
}
|
||||||
|
|
||||||
fn get_like_object_id<Activity>(like_or_dislike: &Activity) -> Result<Url, LemmyError>
|
fn get_like_object_id<Activity>(like_or_dislike: &Activity) -> Result<Url, LemmyError>
|
||||||
|
|
|
@ -396,5 +396,5 @@ async fn find_community_or_private_message_by_id(
|
||||||
return Ok(CommunityOrPrivateMessage::PrivateMessage(p));
|
return Ok(CommunityOrPrivateMessage::PrivateMessage(p));
|
||||||
}
|
}
|
||||||
|
|
||||||
return Err(NotFound.into());
|
Err(NotFound.into())
|
||||||
}
|
}
|
||||||
|
|
|
@ -118,7 +118,7 @@ impl FromApub for Comment {
|
||||||
Comment::delete(conn, comment.id)
|
Comment::delete(conn, comment.id)
|
||||||
})
|
})
|
||||||
.await??;
|
.await??;
|
||||||
return Err(anyhow!("Post is locked").into());
|
Err(anyhow!("Post is locked").into())
|
||||||
} else {
|
} else {
|
||||||
Ok(comment)
|
Ok(comment)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue