change this to:
float f = dht.readTemperature();
you are also sending data at a very rapid rate from the main loop. Have a look at this topic Sending MQTT messages within rate limits
change this to:
float f = dht.readTemperature();
you are also sending data at a very rapid rate from the main loop. Have a look at this topic Sending MQTT messages within rate limits