Skip to content

Commit 218ed47

Browse files
pjungkampsdroege
authored andcommitted
Replace map_or with is_none_or to satisfy clippy
1 parent fa95f55 commit 218ed47

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

gio/src/gio_future.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ where
115115
&& self
116116
.receiver
117117
.as_ref()
118-
.map_or(true, |receiver| receiver.is_terminated())
118+
.is_none_or(|receiver| receiver.is_terminated())
119119
}
120120
}
121121

glib/src/source_futures.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ where
101101
&& self
102102
.source
103103
.as_ref()
104-
.map_or(true, |(_, receiver)| receiver.is_terminated())
104+
.is_none_or(|(_, receiver)| receiver.is_terminated())
105105
}
106106
}
107107

@@ -313,7 +313,7 @@ where
313313
&& self
314314
.source
315315
.as_ref()
316-
.map_or(true, |(_, receiver)| receiver.is_terminated())
316+
.is_none_or(|(_, receiver)| receiver.is_terminated())
317317
}
318318
}
319319

0 commit comments

Comments
 (0)