From 858e6f2c63b4c9328cf8d1a130efb3287b7d3266 Mon Sep 17 00:00:00 2001 From: LailaTheElf Date: Thu, 30 Jan 2025 11:40:16 +0100 Subject: [PATCH] hihi, use the new qos and retain fields --- src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib.rs b/src/lib.rs index 3f46891..dcfa189 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -77,7 +77,7 @@ pub mod mqtt_client { Err(e) => println!("ERROR: publisher: failed to receve an message ({})", e), Ok(msg) => { println!("INFO : publisher: topic={}; payload={}", msg.topic, msg.payload); - match client.publish(msg.topic, QoS::AtMostOnce, false, msg.payload) { + match client.publish(msg.topic, msg.qos, msg.retain, msg.payload) { Err(_n) => println!("ERROR: publisher: failed to publish"), Ok(_n) => {} }