Skip to content

Commit

Permalink
fix: /subscriptions might return empty list
Browse files Browse the repository at this point in the history
  • Loading branch information
Devdutt Shenoi committed Aug 12, 2024
1 parent 90b9055 commit ebecd75
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion uplink/src/collector/bus/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ impl BusTx {
let body = get(url).await?.bytes().await?;
let subscriptions: HashMap<String, Vec<String>> = serde_json::from_slice(&body)?;

if !subscriptions.contains_key(&topic) {
if subscriptions.get(&topic).is_some_and(|s| !s.is_empty()) {
return Err(Error::NoRoute);
}

Expand Down

0 comments on commit ebecd75

Please sign in to comment.