mirror of
https://github.com/signalapp/Signal-Desktop.git
synced 2026-05-08 08:58:38 +01:00
Sender Key: Prepare for testing in beta
This commit is contained in:
@@ -7,7 +7,8 @@ import {
|
||||
} from '@signalapp/signal-client';
|
||||
import { isNumber } from 'lodash';
|
||||
|
||||
import { assert } from './assert';
|
||||
import { isBeta } from './version';
|
||||
import { strictAssert } from './assert';
|
||||
import { getSendOptions } from './getSendOptions';
|
||||
import { handleMessageSend } from './handleMessageSend';
|
||||
import { isGroupV2 } from './whatTypeOfConversation';
|
||||
@@ -116,13 +117,11 @@ export async function onRetryRequest(event: RetryRequestEvent): Promise<void> {
|
||||
}
|
||||
|
||||
function maybeShowDecryptionToast(logId: string) {
|
||||
if (!RemoteConfig.isEnabled('desktop.internalUser')) {
|
||||
if (!isBeta(window.getVersion())) {
|
||||
return;
|
||||
}
|
||||
|
||||
window.log.info(
|
||||
`onDecryptionError/${logId}: Showing toast for internal user`
|
||||
);
|
||||
window.log.info(`onDecryptionError/${logId}: Showing decryption error toast`);
|
||||
window.Whisper.ToastView.show(
|
||||
window.Whisper.DecryptionErrorToast,
|
||||
document.getElementsByClassName('conversation-stack')[0]
|
||||
@@ -434,7 +433,7 @@ async function requestResend(decryptionError: DecryptionErrorEventData) {
|
||||
// We believe that it could be successfully re-sent, so we'll add a placeholder.
|
||||
if (contentHint === ContentHint.RESENDABLE) {
|
||||
const { retryPlaceholders } = window.Signal.Services;
|
||||
assert(retryPlaceholders, 'requestResend: adding placeholder');
|
||||
strictAssert(retryPlaceholders, 'requestResend: adding placeholder');
|
||||
|
||||
window.log.info(`requestResend/${logId}: Adding placeholder`);
|
||||
|
||||
|
||||
@@ -18,7 +18,6 @@ import {
|
||||
SenderCertificateMode,
|
||||
SendLogCallbackType,
|
||||
} from '../textsecure/OutgoingMessage';
|
||||
import { isEnabled } from '../RemoteConfig';
|
||||
|
||||
import { isOlderThan } from './timestamp';
|
||||
import {
|
||||
@@ -142,7 +141,6 @@ export async function sendContentMessageToGroup({
|
||||
const ourConversation = window.ConversationController.get(ourConversationId);
|
||||
|
||||
if (
|
||||
isEnabled('desktop.sendSenderKey2') &&
|
||||
ourConversation?.get('capabilities')?.senderKey &&
|
||||
isGroupV2(conversation.attributes)
|
||||
) {
|
||||
|
||||
Reference in New Issue
Block a user