mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-21 17:29:32 +01:00
Remove some outdated internal settings.
This commit is contained in:
@@ -47,7 +47,7 @@ public final class GroupManager {
|
||||
int disappearingMessagesTimer)
|
||||
throws GroupChangeBusyException, GroupChangeFailedException, IOException
|
||||
{
|
||||
boolean shouldAttemptToCreateV2 = !mms && !SignalStore.internalValues().gv2DoNotCreateGv2Groups();
|
||||
boolean shouldAttemptToCreateV2 = !mms;
|
||||
Set<RecipientId> memberIds = getMemberIds(members);
|
||||
|
||||
if (shouldAttemptToCreateV2) {
|
||||
|
||||
@@ -81,11 +81,6 @@ public final class GroupsV1MigrationUtil {
|
||||
throw new InvalidMigrationStateException();
|
||||
}
|
||||
|
||||
if (!forced && SignalStore.internalValues().disableGv1AutoMigrateInitiation()) {
|
||||
Log.w(TAG, "Auto migration initiation has been disabled! Skipping.");
|
||||
throw new InvalidMigrationStateException();
|
||||
}
|
||||
|
||||
List<Recipient> registeredMembers = RecipientUtil.getEligibleForSending(Recipient.resolvedList(groupRecipient.getParticipantIds()));
|
||||
|
||||
if (RecipientUtil.ensureUuidsAreAvailable(context, registeredMembers)) {
|
||||
@@ -136,7 +131,7 @@ public final class GroupsV1MigrationUtil {
|
||||
|
||||
DecryptedGroup decryptedGroup = performLocalMigration(context, gv1Id, threadId, groupRecipient);
|
||||
|
||||
if (newlyCreated && decryptedGroup != null && !SignalStore.internalValues().disableGv1AutoMigrateNotification()) {
|
||||
if (newlyCreated && decryptedGroup != null) {
|
||||
Log.i(TAG, "Sending no-op update to notify others.");
|
||||
GroupManager.sendNoopUpdate(context, gv2MasterKey, decryptedGroup);
|
||||
}
|
||||
|
||||
@@ -50,17 +50,8 @@ public final class AddGroupDetailsViewModel extends ViewModel {
|
||||
MutableLiveData<List<GroupMemberEntry.NewGroupCandidate>> initialMembers = new MutableLiveData<>();
|
||||
LiveData<Boolean> isValidName = Transformations.map(name, name -> !TextUtils.isEmpty(name));
|
||||
|
||||
members = LiveDataUtil.combineLatest(initialMembers, deleted, AddGroupDetailsViewModel::filterDeletedMembers);
|
||||
isMms = Transformations.map(members, AddGroupDetailsViewModel::isAnyForcedSms);
|
||||
|
||||
LiveData<List<GroupMemberEntry.NewGroupCandidate>> membersToCheckGv2CapabilityOf = LiveDataUtil.combineLatest(isMms, members, (forcedMms, memberList) -> {
|
||||
if (SignalStore.internalValues().gv2DoNotCreateGv2Groups() || forcedMms) {
|
||||
return Collections.emptyList();
|
||||
} else {
|
||||
return memberList;
|
||||
}
|
||||
});
|
||||
|
||||
members = LiveDataUtil.combineLatest(initialMembers, deleted, AddGroupDetailsViewModel::filterDeletedMembers);
|
||||
isMms = Transformations.map(members, AddGroupDetailsViewModel::isAnyForcedSms);
|
||||
canSubmitForm = LiveDataUtil.combineLatest(isMms, isValidName, (mms, validName) -> mms || validName);
|
||||
|
||||
repository.resolveMembers(recipientIds, initialMembers::postValue);
|
||||
|
||||
Reference in New Issue
Block a user