]> gitweb.stoutner.com Git - PrivacyCell.git/blobdiff - app/src/main/java/com/stoutner/privacycell/fragments/SettingsFragment.kt
Create a protocols activity. https://redmine.stoutner.com/issues/774
[PrivacyCell.git] / app / src / main / java / com / stoutner / privacycell / fragments / SettingsFragment.kt
index dd8c9c728fd08ffa4864c4c76701615a8e507bb3..3708bc225716db77487878f5a1be766cdea89218 100644 (file)
@@ -49,7 +49,7 @@ class SettingsFragment : PreferenceFragmentCompat() {
         setPreferencesFromResource(R.xml.preferences, rootKey)
 
         // Get a handle for the shared preferences.
-        val sharedPreferences = preferenceScreen.sharedPreferences
+        val sharedPreferences = preferenceScreen.sharedPreferences!!
 
         // Get handles for the preferences.
         realtimeMonitoringPreference = findPreference(getString(R.string.realtime_monitoring_key))!!
@@ -107,7 +107,7 @@ class SettingsFragment : PreferenceFragmentCompat() {
         super.onPause()
 
         // Get a handle for the shared preferences.
-        val sharedPreferences = preferenceScreen.sharedPreferences
+        val sharedPreferences = preferenceScreen.sharedPreferences!!
 
         // Unregister the shared preference listener.
         sharedPreferences.unregisterOnSharedPreferenceChangeListener(sharedPreferenceChangeListener)
@@ -122,7 +122,7 @@ class SettingsFragment : PreferenceFragmentCompat() {
         sharedPreferenceChangeListener = getSharedPreferenceChangeListener()
 
         // Get a handle for the shared preferences.
-        val sharedPreferences = preferenceScreen.sharedPreferences
+        val sharedPreferences = preferenceScreen.sharedPreferences!!
 
         // Re-register the shared preference listener.
         sharedPreferences.registerOnSharedPreferenceChangeListener(sharedPreferenceChangeListener)