mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-02-22 02:36:55 +00:00
Only update SMS setting if registration is complete.
Otherwise you could crash during registration if the user had previously set Signal as the default.
This commit is contained in:
@@ -359,7 +359,7 @@ public final class SettingsValues extends SignalStoreValues {
|
||||
public void setDefaultSms(boolean value) {
|
||||
boolean lastKnown = getBoolean(DEFAULT_SMS, false);
|
||||
|
||||
if (value != lastKnown) {
|
||||
if (value != lastKnown && SignalStore.registrationValues().isRegistrationComplete()) {
|
||||
Log.i(TAG, "Default SMS state changed! Scheduling a storage sync.");
|
||||
putBoolean(DEFAULT_SMS, value);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user