Merge "Use updated DeviceConfig API's new getters to simplify invocations."

This commit is contained in:
TreeHugger Robot
2019-03-08 13:43:05 +00:00
committed by Android (Google) Code Review

View File

@@ -127,8 +127,7 @@ public class AttentionManagerService extends SystemService {
}
private boolean isServiceEnabled() {
final String enabled = DeviceConfig.getProperty(NAMESPACE, SERVICE_ENABLED);
return enabled == null ? DEFAULT_SERVICE_ENABLED : "true".equals(enabled);
return DeviceConfig.getBoolean(NAMESPACE, SERVICE_ENABLED, DEFAULT_SERVICE_ENABLED);
}
/**