Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 716a734e authored by Jorim Jaggi's avatar Jorim Jaggi
Browse files

Fix trigger sensor lifecycle

Make sure the mRegistered flag is updated early enough, so we don't
call cancel if we are not registered.

Bug: 23105138
Change-Id: I1feeab9ea3d0ca31eb5deaab97f6de2cfc4c3b3d
parent aa1fd4e6
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -534,8 +534,8 @@ public class DozeService extends DreamService {
                    }
                }

                requestPulse(mPulseReason);
                mRegistered = false;
                requestPulse(mPulseReason);
                updateListener();  // reregister, this sensor only fires once

                // reset the notification pulse schedule, but only if we think we were not triggered