chore: remove the unblockGroupToSend string as we cannot block a group.

pull/2820/head
Audric Ackermann 2 years ago
parent 873a2d5ad5
commit 0e5ca3f731

@ -181,7 +181,6 @@
"messageBodyMissing": "Please enter a message body.",
"messageBody": "Message body",
"unblockToSend": "Unblock this contact to send a message.",
"unblockGroupToSend": "This group is blocked. Unlock it if you would like to send a message.",
"youChangedTheTimer": "You set the disappearing message timer to $time$",
"timerSetOnSync": "Updated disappearing message timer to $time$",
"theyChangedTheTimer": "$name$ set the disappearing message timer to $time$",

@ -472,16 +472,13 @@ class CompositionBoxInner extends React.Component<Props, State> {
if (left) {
return i18n('youLeftTheGroup');
}
if (isBlocked && isPrivate) {
if (isBlocked) {
return i18n('unblockToSend');
}
if (isBlocked && !isPrivate) {
return i18n('unblockGroupToSend');
}
return i18n('sendMessage');
};
const { isKickedFromGroup, left, isPrivate, isBlocked } = this.props.selectedConversation;
const { isKickedFromGroup, left, isBlocked } = this.props.selectedConversation;
const messagePlaceHolder = makeMessagePlaceHolderText();
const { typingEnabled } = this.props;
const neverMatchingRegex = /($a)/;
@ -858,14 +855,10 @@ class CompositionBoxInner extends React.Component<Props, State> {
return;
}
if (selectedConversation.isBlocked && selectedConversation.isPrivate) {
if (selectedConversation.isBlocked) {
ToastUtils.pushUnblockToSend();
return;
}
if (selectedConversation.isBlocked && !selectedConversation.isPrivate) {
ToastUtils.pushUnblockToSendGroup();
return;
}
// Verify message length
const msgLen = messagePlaintext?.length || 0;
if (msgLen === 0 && this.props.stagedAttachments?.length === 0) {

@ -201,10 +201,6 @@ export function pushUnblockToSend() {
pushToastInfo('unblockToSend', window.i18n('unblockToSend'));
}
export function pushUnblockToSendGroup() {
pushToastInfo('unblockGroupToSend', window.i18n('unblockGroupToSend'));
}
export function pushYouLeftTheGroup() {
pushToastError('youLeftTheGroup', window.i18n('youLeftTheGroup'));
}

@ -181,7 +181,6 @@ export type LocalizerKeys =
| 'messageBodyMissing'
| 'messageBody'
| 'unblockToSend'
| 'unblockGroupToSend'
| 'youChangedTheTimer'
| 'timerSetOnSync'
| 'theyChangedTheTimer'

Loading…
Cancel
Save