Merge "Fix incorrect message being sent for all intents."

This commit is contained in:
TreeHugger Robot
2022-12-13 19:33:53 +00:00
committed by Android (Google) Code Review

View File

@@ -2187,8 +2187,10 @@ public class AppStandbyController
}
// component-level enable/disable can affect bucketing, so we always
// reevaluate that for any PACKAGE_CHANGED
mHandler.obtainMessage(MSG_CHECK_PACKAGE_IDLE_STATE, userId, -1, pkgName)
.sendToTarget();
if (Intent.ACTION_PACKAGE_CHANGED.equals(action)) {
mHandler.obtainMessage(MSG_CHECK_PACKAGE_IDLE_STATE, userId, -1, pkgName)
.sendToTarget();
}
}
if ((Intent.ACTION_PACKAGE_REMOVED.equals(action) ||
Intent.ACTION_PACKAGE_ADDED.equals(action))) {