Skip to content

Commit c082797

Browse files
authored
Merge pull request #672 from AdamWill/set-on-battery-before-switch-profile
controller init: set _on_battery before switching profile
2 parents 0a85d3c + 1831343 commit c082797

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

tuned/ppd/controller.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,8 +138,8 @@ def initialize(self):
138138
self._config = PPDConfig(PPD_CONFIG_FILE)
139139
active_profile = self.active_profile()
140140
self._base_profile = active_profile if active_profile != UNKNOWN_PROFILE else self._config.default_profile
141-
self.switch_profile(self._base_profile)
142141
self._on_battery = False
142+
self.switch_profile(self._base_profile)
143143
if self._config.battery_detection:
144144
self.setup_battery_signaling()
145145

0 commit comments

Comments
 (0)