From 2ab5da8543501a1b53c8ae4ea2fcdbedb295f7af Mon Sep 17 00:00:00 2001 From: Sam Bosley Date: Tue, 18 Sep 2012 10:16:06 -0700 Subject: [PATCH] Fixed a crash in preferences --- astrid/src/com/todoroo/astrid/activity/EditPreferences.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/astrid/src/com/todoroo/astrid/activity/EditPreferences.java b/astrid/src/com/todoroo/astrid/activity/EditPreferences.java index b96bb5b19..e41d9fbb0 100644 --- a/astrid/src/com/todoroo/astrid/activity/EditPreferences.java +++ b/astrid/src/com/todoroo/astrid/activity/EditPreferences.java @@ -703,7 +703,8 @@ public class EditPreferences extends TodorooPreferenceActivity { private void onVoiceInputStatusChanged(final Preference preference, boolean newValue) { if(!newValue) return; - if (AndroidUtilities.indexOf(Constants.MARKET_STRATEGY.excludedSettings(), R.string.p_voiceInputEnabled) >= 0) + int[] excludedSettings = Constants.MARKET_STRATEGY.excludedSettings(); + if (excludedSettings != null && AndroidUtilities.indexOf(excludedSettings, R.string.p_voiceInputEnabled) >= 0) return; final Resources r = getResources();