diff --git a/Adafruit_MQTT.h b/Adafruit_MQTT.h index d06ce7a..e18110e 100644 --- a/Adafruit_MQTT.h +++ b/Adafruit_MQTT.h @@ -128,8 +128,8 @@ class Adafruit_MQTT { // if the message was published, false otherwise. // The topic must be stored in PROGMEM. It can either be a // char*, or a __FlashStringHelper* (the result of the F() macro). - bool publish(const char *topic, const char *payload, uint8_t qos); - bool publish(const __FlashStringHelper *topic, const char *payload, uint8_t qos) { + bool publish(const char *topic, const char *payload, uint8_t qos = 0); + bool publish(const __FlashStringHelper *topic, const char *payload, uint8_t qos = 0) { return publish((const char *)topic, payload, qos); }