Add null check for lifecycle
- Add a null check so that search works correctly in DevelopmentSettingsDashboardFragment Bug: 34203528 Test: Manual Testing Change-Id: I26e84d2dcb403a2e68d092056a6c8940becedeff
This commit is contained in:
@@ -68,7 +68,7 @@ public abstract class AbstractLogpersistPreferenceController extends
|
||||
|
||||
public AbstractLogpersistPreferenceController(Context context, Lifecycle lifecycle) {
|
||||
super(context);
|
||||
if (isAvailable()) {
|
||||
if (isAvailable() && lifecycle != null) {
|
||||
lifecycle.addObserver(this);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user