summaryrefslogtreecommitdiffstats
path: root/src/mycelium.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/mycelium.rs')
-rw-r--r--src/mycelium.rs10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/mycelium.rs b/src/mycelium.rs
index 3471f71..8d0821b 100644
--- a/src/mycelium.rs
+++ b/src/mycelium.rs
@@ -33,7 +33,6 @@ const TOPIC_PONG: &str = "continuum.v1.pong";
const EMPTY_QUEUE_DELAY: Duration = Duration::from_millis(25);
-
#[derive(Debug, Deserialize)]
#[serde(rename_all = "camelCase")]
struct InboundMessage {
@@ -555,10 +554,7 @@ impl Transport for MyceliumTransport {
}
async fn send_encoded(&self, message: &EncodedMessage) -> Result<()> {
- tracing::debug!(
- payload_bytes = message.body.len(),
- "Sending message"
- );
+ tracing::debug!(payload_bytes = message.body.len(), "Sending message");
let response = self
.client
.post(self.messages_endpoint.clone())
@@ -700,9 +696,7 @@ fn decode_payload(topic: &str, payload: &str) -> Result<ParsedMessage, Transport
}
TOPIC_PING => Ok(ParsedMessage::Ping(bytes_to_keepalive(&bytes)?)),
TOPIC_PONG => Ok(ParsedMessage::Pong(bytes_to_keepalive(&bytes)?)),
- t => {
- Err(TransportError::UnknownTopic(t.to_string()))
- }
+ t => Err(TransportError::UnknownTopic(t.to_string())),
}
}