Replaced a bunch of log by log_info
This commit is contained in:
1 parent
098e95b439
commit
533785151e
4 files changed
+27
-27
No files matched your search
+2
-2
@@ -190,7 +190,7 @@ class SmartLight(SmartSwitch):
|
||||
def on_turn_on_with_transition(self, event_name, data, event_category):
|
||||
transition_time = self.args["on_events_with_transition"][event_category]["transition_time"]
|
||||
brightness_pct = self.args["on_events_with_transition"][event_category]["brightness_pct"]
|
||||
self.log(f"Turn on at {brightness_pct}% with a transition of {transition_time}s")
|
||||
self.log_info(f"Turn on at {brightness_pct}% with a transition of {transition_time}s")
|
||||
self.call_service("light/turn_on", entity_id = self.entity_id,brightness_pct = 1)
|
||||
self.call_service("light/turn_on", entity_id = self.entity_id, transition = transition_time,brightness_pct = brightness_pct)
|
||||
|
||||
@@ -210,7 +210,7 @@ class SmartLight(SmartSwitch):
|
||||
# Override: apply light_brightness_pct when turning on, if one is active.
|
||||
def switch_on(self):
|
||||
if self.light_brightness_pct != None:
|
||||
self.log(f"Turn on {self.entity_id} at {self.light_brightness_pct}%")
|
||||
self.log_info(f"Turn on {self.entity_id} at {self.light_brightness_pct}%")
|
||||
self.call_service("light/turn_on", entity_id = self.entity_id,brightness_pct = self.light_brightness_pct)
|
||||
else:
|
||||
super().switch_on()
|
||||
|
||||
Reference in new issue
Block a user