timestamp added
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/tag/woodpecker Pipeline was successful

This commit is contained in:
2024-01-14 15:09:41 +01:00
parent 0215d2efd1
commit 4a56fea33b
2 changed files with 4 additions and 1 deletions

View File

@ -45,7 +45,7 @@ func (self *MqttHandle) Publish(topicPost string, message string) error {
}
topic := fmt.Sprintf("%s/%s", self.pubTopic, topicPost)
token := self.client.Publish(topic, 0, false, message)
token := self.client.Publish(topic, 0, true, message)
token.Wait()
if token.Error() != nil {
return fmt.Errorf("MQTT publish failed: %v", token.Error())