diff --git a/src/mqtt_client_wrapper.cpp b/src/mqtt_client_wrapper.cpp index 1c76914..561560e 100644 --- a/src/mqtt_client_wrapper.cpp +++ b/src/mqtt_client_wrapper.cpp @@ -39,7 +39,7 @@ void mqtt_client_thread_func() { while (true) { - const auto &cfg = g_app_config; + const auto &cfg = g_app_config.mqtt; mqtt_client = std::make_unique(cfg); mqtt_client->setConnectCallback(on_mqtt_connected);