Fixing local variable error
This commit is contained in:
@@ -52,10 +52,11 @@ def getValues(sensor):
|
||||
temp = round(temp, 2)
|
||||
#print("Temperature: {}*F Humidity: {}% ".format(temp, humidity))
|
||||
result = 1
|
||||
return temp, humidity
|
||||
except RuntimeError as error:
|
||||
print(error.args[0])
|
||||
time.sleep(2.0)
|
||||
return temp, humidity
|
||||
|
||||
|
||||
|
||||
def publish(client, temp, humidity):
|
||||
|
||||
Reference in New Issue
Block a user