From 7c9350a940b4f96eb092c0dc2a7169b9e20b35ef Mon Sep 17 00:00:00 2001 From: Julia Reynolds Date: Thu, 21 Apr 2016 10:24:27 -0400 Subject: [PATCH] Always reevaluate rules when a new service is added. Otherwise the condition providers may never get an onSubscribe call and may not turn on at the right time. Bug: 26981870 Change-Id: Ia622597f10cc26f7c34ece1748013655543f488f --- .../com/android/server/notification/ZenModeConditions.java | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/services/core/java/com/android/server/notification/ZenModeConditions.java b/services/core/java/com/android/server/notification/ZenModeConditions.java index 0945065d62f7e..86ca97d485315 100644 --- a/services/core/java/com/android/server/notification/ZenModeConditions.java +++ b/services/core/java/com/android/server/notification/ZenModeConditions.java @@ -99,9 +99,7 @@ public class ZenModeConditions implements ConditionProviders.Callback { @Override public void onServiceAdded(ComponentName component) { if (DEBUG) Log.d(TAG, "onServiceAdded " + component); - if (isAutomaticActive(component)) { - mHelper.setConfigAsync(mHelper.getConfig(), "zmc.onServiceAdded"); - } + mHelper.setConfigAsync(mHelper.getConfig(), "zmc.onServiceAdded"); } @Override