Merge "Protect against work conditional crash" into nyc-mr1-dev
This commit is contained in:
@@ -90,7 +90,9 @@ public class WorkModeCondition extends Condition {
|
|||||||
@Override
|
@Override
|
||||||
public void onActionClick(int index) {
|
public void onActionClick(int index) {
|
||||||
if (index == 0) {
|
if (index == 0) {
|
||||||
|
if (mUserHandle != null) {
|
||||||
mUm.trySetQuietModeDisabled(mUserHandle.getIdentifier(), null);
|
mUm.trySetQuietModeDisabled(mUserHandle.getIdentifier(), null);
|
||||||
|
}
|
||||||
setActive(false);
|
setActive(false);
|
||||||
} else {
|
} else {
|
||||||
throw new IllegalArgumentException("Unexpected index " + index);
|
throw new IllegalArgumentException("Unexpected index " + index);
|
||||||
|
Reference in New Issue
Block a user