diff --git a/src/mqtt_client_wrapper.cpp b/src/mqtt_client_wrapper.cpp index b868120..9f8ba15 100644 --- a/src/mqtt_client_wrapper.cpp +++ b/src/mqtt_client_wrapper.cpp @@ -201,7 +201,7 @@ static void on_mqtt_message_received(const std::string &topic, const std::string void mqtt_client_thread_func() { const auto &cfg = g_app_config.mqtt; - auto heartbeat_interval = std::chrono::milliseconds(static_cast(cfg.mqtt.keep_alive * 0.9)); + auto heartbeat_interval = std::chrono::milliseconds(static_cast(cfg.keep_alive * 0.9)); while (g_running) {