Skip to content

Commit cc987d6

Browse files
committed
Entry is a set(), just check for "preset" in entry
1 parent 65f790b commit cc987d6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

plugwise/helper.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1250,7 +1250,7 @@ def _schedules(
12501250
LOGGER.debug("HOI %s", entry)
12511251
# keys, dummy = zip(*entry.items())
12521252
# LOGGER.debug("HOI 1 %s", keys)
1253-
if entry.keys()[0] == "preset":
1253+
if "preset" in entry:
12541254
schedule[directive.attrib["time"]] = [
12551255
float(self._presets(loc_id)[entry["preset"]][0]),
12561256
float(self._presets(loc_id)[entry["preset"]][1]),

0 commit comments

Comments
 (0)