fix wrong indentation

This commit is contained in:
interfisch 2021-07-01 21:28:50 +02:00
parent 29b04c7d00
commit 5073aec1dd
1 changed files with 7 additions and 7 deletions

View File

@ -49,13 +49,13 @@ class Controller:
print("msg = " + msg)
if message.topic.endswith(__TOPIC_BRIGHTNESS__ + "/set"):
val = float(msg)
if val >= 0.0 and val <=1.0:
self.display.brightness = val
print("changed brightness to ", self.display.brightness)
self.mqtt.publish(self.topic + "/" + __TOPIC_BRIGHTNESS__, self.display.brightness, 1 )
else:
print("invalid brightness ", val)
val = float(msg)
if val >= 0.0 and val <=1.0:
self.display.brightness = val
print("changed brightness to ", self.display.brightness)
self.mqtt.publish(self.topic + "/" + __TOPIC_BRIGHTNESS__, self.display.brightness, 1 )
else:
print("invalid brightness ", val)
if message.topic.endswith(__TOPIC_SCROLL_INTERVAL__ + "/set"):
val = float(msg)