mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-21 09:20:19 +01:00
Fix race condition overriding profile on registration.
This commit is contained in:
committed by
Alex Hart
parent
e2cb522e87
commit
e687fea567
@@ -10,6 +10,7 @@ public final class RegistrationValues extends SignalStoreValues {
|
||||
|
||||
private static final String REGISTRATION_COMPLETE = "registration.complete";
|
||||
private static final String PIN_REQUIRED = "registration.pin_required";
|
||||
private static final String HAS_UPLOADED_PROFILE = "registration.has_uploaded_profile";
|
||||
|
||||
RegistrationValues(@NonNull KeyValueStore store) {
|
||||
super(store);
|
||||
@@ -46,4 +47,12 @@ public final class RegistrationValues extends SignalStoreValues {
|
||||
public synchronized boolean isRegistrationComplete() {
|
||||
return getStore().getBoolean(REGISTRATION_COMPLETE, true);
|
||||
}
|
||||
|
||||
public boolean hasUploadedProfile() {
|
||||
return getBoolean(HAS_UPLOADED_PROFILE, false);
|
||||
}
|
||||
|
||||
public void markHasUploadedProfile() {
|
||||
putBoolean(HAS_UPLOADED_PROFILE, true);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user