Skip to content

Commit

Permalink
chore: clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
huitseeker committed Nov 29, 2024
1 parent c224094 commit 7771913
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/channel.rs
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ pub struct Permit<'a, T> {
_permit: mpsc::Permit<'a, T>,
}

impl<'a, T> Permit<'a, T> {
impl<T> Permit<'_, T> {
/// Send a value using this permit
pub fn send(self, value: T) {
self._permit.send(value);
Expand Down Expand Up @@ -130,7 +130,7 @@ impl<T> Receiver<T> {
pub async fn recv(&mut self) -> Option<T> {
debug!("waiting to receive value");
let msg = self.inner.recv().await;
if let Some(_) = &msg {
if msg.is_some() {
self.gauge.dec();
debug!("value received successfully");
} else {
Expand Down

0 comments on commit 7771913

Please sign in to comment.