mirror of
https://github.com/LemmyNet/lemmy.git
synced 2025-03-27 22:02:54 +00:00
Remove usage of is_okay_and for Rust 1.67 compatibility
This commit is contained in:
parent
1cd4003bdc
commit
1aa2adf2f9
1 changed files with 2 additions and 5 deletions
|
@ -92,11 +92,8 @@ impl CommunityView {
|
|||
) -> Result<bool, Error> {
|
||||
let is_mod = CommunityModeratorView::for_community(pool, community_id)
|
||||
.await
|
||||
.is_ok_and(|v| {
|
||||
v.into_iter()
|
||||
.map(|m| m.moderator.id)
|
||||
.any(|i| i == person_id)
|
||||
});
|
||||
.map(|v| v.into_iter().any(|m| m.moderator.id == person_id))
|
||||
.unwrap_or(false);
|
||||
if is_mod {
|
||||
return Ok(true);
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue