Change topics concatenation method
Correct regression introduced by #503 Nevertheless this method needs to be optimized to avoid the use of string.
This commit is contained in:
1 parent
c0ddf77c9f
commit
7f16d00a55
12 files changed
+23
-23
No files matched your search
@@ -33,7 +33,7 @@
|
||||
#ifdef jsonReceiving
|
||||
void MQTTtoONOFF(char * topicOri, JsonObject& ONOFFdata){
|
||||
|
||||
if (strstr(topicOri,catToMainTopic(subjectMQTTtoONOFF)) != NULL){
|
||||
if (strstr(topicOri,(char *)catToMainTopic(subjectMQTTtoONOFF).c_str()) != NULL){
|
||||
trc(F("MQTTtoONOFF json data analysis"));
|
||||
int boolSWITCHTYPE = ONOFFdata["state"] | 99;
|
||||
int pin = ONOFFdata["pin"] | ACTUATOR_ONOFF_PIN;
|
||||
@@ -55,7 +55,7 @@ void MQTTtoONOFF(char * topicOri, JsonObject& ONOFFdata){
|
||||
|
||||
#ifdef simpleReceiving
|
||||
void MQTTtoONOFF(char * topicOri, char * datacallback) {
|
||||
if ((strstr(topicOri,catToMainTopic(subjectMQTTtoONOFF)) != NULL) ){
|
||||
if ((strstr(topicOri,(char *)catToMainTopic(subjectMQTTtoONOFF).c_str()) != NULL) ){
|
||||
|
||||
trc(F("MQTTtoONOFF"));
|
||||
int pin = strtol(datacallback, NULL, 10); // we will not be able to pass values > 4294967295
|
||||
|
||||
Reference in new issue
Block a user