     remoteClient.loop();
     
     if (millis() - lastPublishTime > publishingPeriod) {
-      lastPublishTime = millis();
+      lastPublishTime = millis(); 
       remoteClient.publishTemperature(temp);
       delay(200);
       remoteClient.publishSetTemperature(targetTemp);

#define PASSWORD "pwd"

#define DEFAULT_TARGET_TEMP 19

#define COOL_PIN 13
#define HEAT_PIN 14
#define DHTPIN 12

#define TEMPERATURE_CONTROL_RANGE 1

#include <PubSubClient.h> 
#include <ESP8266WiFi.h>
#include <DHT.h>
#include <EEPROM.h>
