In the [Udacity Android development video](https://www.udacity.com/course/viewer#!/c-ud853/l-1474559101/e-1643578589/m-1643578588) on Modifying SettingsActivity, I implemented the code as per [this gist](https://github.com/udacity/Sunshine-Version-2/blob/5204747e9378f65bf4a474da4b5c08f61a64d37c/app/src/main/java/com/example/android/sunshine/app/SettingsActivity.java) but am getting an error on Android Monitor saying 

> 
> 03-18 10:52:59.625: E/AndroidRuntime(2520): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.example.android.sunshine/com.example.android.sunshine.SettingsActivity}: java.lang.NullPointerException: Attempt to invoke virtual method 'void android.preference.Preference.setOnPreferenceChangeListener(android.preference.Preference$OnPreferenceChangeListener)' on a null object reference
> 
> 
> 

The relevant code is

```
   private void bindPreferenceSummaryToValue(Preference preference) {
    // Set the listener to watch for value changes.
    preference.setOnPreferenceChangeListener(this);

    // Trigger the listener immediately with the preference's
    // current value.
    onPreferenceChange(preference,
            PreferenceManager
                    .getDefaultSharedPreferences(preference.getContext())
                    .getString(preference.getKey(), ""));
}

```

So it looks like `this` is undefined, is that right?