mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-22 09:49:30 +01:00
Add ability to hide contacts behind a feature flag.
This commit is contained in:
committed by
Cody Henthorne
parent
a8a773db43
commit
04eeb434c9
@@ -106,6 +106,7 @@ public final class FeatureFlags {
|
||||
private static final String SMS_EXPORTER = "android.sms.exporter";
|
||||
private static final String CDS_V2_COMPAT = "android.cdsV2Compat.3";
|
||||
public static final String STORIES_LOCALE = "android.stories.locale";
|
||||
private static final String HIDE_CONTACTS = "android.hide.contacts";
|
||||
|
||||
/**
|
||||
* We will only store remote values for flags in this set. If you want a flag to be controllable
|
||||
@@ -163,7 +164,8 @@ public final class FeatureFlags {
|
||||
CDS_V2_LOAD_TEST,
|
||||
SMS_EXPORTER,
|
||||
CDS_V2_COMPAT,
|
||||
STORIES_LOCALE
|
||||
STORIES_LOCALE,
|
||||
HIDE_CONTACTS
|
||||
);
|
||||
|
||||
@VisibleForTesting
|
||||
@@ -588,6 +590,16 @@ public final class FeatureFlags {
|
||||
return getBoolean(CDS_V2_COMPAT, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* Whether or not users can hide contacts.
|
||||
*
|
||||
* WARNING: This feature is intended to be enabled in tandem with other clients, as it modifies contact records.
|
||||
* Here be dragons.
|
||||
*/
|
||||
public static boolean hideContacts() {
|
||||
return getBoolean(HIDE_CONTACTS, false);
|
||||
}
|
||||
|
||||
/** Only for rendering debug info. */
|
||||
public static synchronized @NonNull Map<String, Object> getMemoryValues() {
|
||||
return new TreeMap<>(REMOTE_VALUES);
|
||||
|
||||
Reference in New Issue
Block a user