[fenix] For https://github.com/mozilla-mobile/fenix/issues/2905: Remove device name during sync logout

pull/600/head
Jonathan Almeida 5 years ago committed by Jonathan Almeida
parent 177098ba41
commit 3a56a72a2e

@ -59,6 +59,12 @@ class AccountSettingsFragment : PreferenceFragmentCompat(), CoroutineScope {
override fun onLoggedOut() {
launch {
Navigation.findNavController(view!!).popBackStack()
// Remove the device name when we log out.
context?.let {
val deviceNameKey = it.getPreferenceKey(R.string.pref_key_sync_device_name)
preferenceManager.sharedPreferences.edit().remove(deviceNameKey).apply()
}
}
}

Loading…
Cancel
Save