diff --git a/app/src/main/java/org/mozilla/fenix/settings/account/AccountSettingsFragment.kt b/app/src/main/java/org/mozilla/fenix/settings/account/AccountSettingsFragment.kt index 85106afcf..05d174884 100644 --- a/app/src/main/java/org/mozilla/fenix/settings/account/AccountSettingsFragment.kt +++ b/app/src/main/java/org/mozilla/fenix/settings/account/AccountSettingsFragment.kt @@ -367,6 +367,7 @@ class AccountSettingsFragment : PreferenceFragmentCompat() { ?.deviceConstellation() ?.setDeviceName(newDeviceName, it) } + accountSettingsStore.dispatch(AccountSettingsFragmentAction.UpdateDeviceName(newDeviceName)) } return true } diff --git a/app/src/main/java/org/mozilla/fenix/settings/account/AccountSettingsInteractor.kt b/app/src/main/java/org/mozilla/fenix/settings/account/AccountSettingsInteractor.kt index 1e63c8508..71e9ca308 100644 --- a/app/src/main/java/org/mozilla/fenix/settings/account/AccountSettingsInteractor.kt +++ b/app/src/main/java/org/mozilla/fenix/settings/account/AccountSettingsInteractor.kt @@ -46,7 +46,8 @@ class AccountSettingsInteractor( } // Our "change the device name on the server" operation may fail. // Currently, we disregard this failure and pretend we succeeded. - // At the same time, when user changes the device name, we immediately update the UI to display the new name. + // At the same time, when user changes the device name, + // we immediately update the UI to display the new name. // So, in case of a network (or other) failure when talking to the server, // we'll have a discrepancy - the UI will reflect new value, but actually the value never changed. // So, when user presses "sync now", we'll fetch the old value, and reset the UI.