diff --git a/internal/linux/powerStateSensor.go b/internal/linux/powerStateSensor.go index ab0f06b64..d001cca88 100644 --- a/internal/linux/powerStateSensor.go +++ b/internal/linux/powerStateSensor.go @@ -45,11 +45,10 @@ func PowerStateUpdater(ctx context.Context, tracker device.SensorTracker) { sensorCh <- newPowerState("Powered On") err := dbushelpers.NewBusRequest(ctx, dbushelpers.SystemBus). - Path("/org/freedesktop/login1"). Match([]dbus.MatchOption{ + dbus.WithMatchObjectPath("/org/freedesktop/login1"), dbus.WithMatchInterface("org.freedesktop.login1.Manager"), }). - Event("org.freedesktop.DBus.Properties.PropertiesChanged"). Handler(func(s *dbus.Signal) { switch s.Name { case "org.freedesktop.login1.Manager.PrepareForSleep":