Skip to content

Commit ea00c34

Browse files
committed
move variable resettting to periodics
1 parent 07fde9f commit ea00c34

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

magicbot/magicrobot.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -729,6 +729,9 @@ def _do_periodics(self) -> None:
729729
self.onException()
730730
else:
731731
setter(value)
732+
733+
for reset_dict, component in self._reset_components:
734+
component.__dict__.update(reset_dict)
732735

733736
watchdog.addEpoch("@magicbot.feedback")
734737

@@ -748,6 +751,3 @@ def _enabled_periodic(self) -> None:
748751
watchdog.addEpoch(name)
749752

750753
self._do_periodics()
751-
752-
for reset_dict, component in self._reset_components:
753-
component.__dict__.update(reset_dict)

0 commit comments

Comments
 (0)