Skip to content

Commit

Permalink
void unused variable
Browse files Browse the repository at this point in the history
  • Loading branch information
bertmelis authored Nov 16, 2023
1 parent b847bd5 commit 5832e6e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/MqttClientSetup.h
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ class MqttClientSetup : public MqttClient {
#ifndef EMC_SINGLE_CALLBACKS
_onConnectCallbacks.emplace_back(callback, id);
#else
(void) id;
_onConnectCallback = callback;
#endif
return static_cast<T&>(*this);
Expand All @@ -91,6 +92,7 @@ class MqttClientSetup : public MqttClient {
#ifndef EMC_SINGLE_CALLBACKS
_onDisconnectCallbacks.emplace_back(callback, id);
#else
(void) id;
_onDisconnectCallback = callback;
#endif
return static_cast<T&>(*this);
Expand All @@ -100,6 +102,7 @@ class MqttClientSetup : public MqttClient {
#ifndef EMC_SINGLE_CALLBACKS
_onSubscribeCallbacks.emplace_back(callback, id);
#else
(void) id;
_onSubscribeCallback = callback;
#endif
return static_cast<T&>(*this);
Expand All @@ -109,6 +112,7 @@ class MqttClientSetup : public MqttClient {
#ifndef EMC_SINGLE_CALLBACKS
_onUnsubscribeCallbacks.emplace_back(callback, id);
#else
(void) id;
_onUnsubscribeCallback = callback;
#endif
return static_cast<T&>(*this);
Expand All @@ -118,6 +122,7 @@ class MqttClientSetup : public MqttClient {
#ifndef EMC_SINGLE_CALLBACKS
_onMessageCallbacks.emplace_back(callback, id);
#else
(void) id;
_onMessageCallback = callback;
#endif
return static_cast<T&>(*this);
Expand All @@ -127,6 +132,7 @@ class MqttClientSetup : public MqttClient {
#ifndef EMC_SINGLE_CALLBACKS
_onPublishCallbacks.emplace_back(callback, id);
#else
(void) id;
_onPublishCallback = callback;
#endif
return static_cast<T&>(*this);
Expand Down

0 comments on commit 5832e6e

Please sign in to comment.