Skip to content

Commit

Permalink
Fix "never type fallback" warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
spacebear21 committed Nov 7, 2024
1 parent 91db443 commit c83b857
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions payjoin-directory/src/db.rs
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,8 @@ impl DbPool {
async fn push(&self, pubkey_id: &str, channel_type: &str, data: Vec<u8>) -> RedisResult<()> {
let mut conn = self.client.get_async_connection().await?;
let key = channel_name(pubkey_id, channel_type);
conn.set(&key, data.clone()).await?;
conn.publish(&key, "updated").await?;
let () = conn.set(&key, data.clone()).await?;
let () = conn.publish(&key, "updated").await?;
Ok(())
}

Expand Down Expand Up @@ -75,8 +75,8 @@ impl DbPool {
loop {
match message_stream.next().await {
Some(msg) => {
msg.get_payload()?; // Notification received
// Try fetching the data again
let () = msg.get_payload()?; // Notification received
// Try fetching the data again
if let Some(data) = conn.get::<_, Option<Vec<u8>>>(&key).await? {
if !data.is_empty() {
break data; // Exit the block, returning the data
Expand Down

0 comments on commit c83b857

Please sign in to comment.