Fixed failure to initialize SharedPreferences variable.