Skip to content

Commit dc426fb

Browse files
committed
extra -> suffix
1 parent 6956a0f commit dc426fb

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

pkg/connector/events.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -341,12 +341,12 @@ func (evt *WAUndecryptableMessage) ConvertMessage(ctx context.Context, portal *b
341341
content := &undecryptableMessageContent
342342
if evt.Type == events.UnavailableTypeViewOnce {
343343
verb := "sent"
344-
extra := ""
344+
suffix := ""
345345
if !evt.Info.IsFromMe {
346346
verb = "received"
347-
extra = " For added privacy, you can only open it on the WhatsApp app."
347+
suffix = " For added privacy, you can only open it on the WhatsApp app."
348348
}
349-
body := fmt.Sprintf("You %s a view once message.%s", verb, extra)
349+
body := fmt.Sprintf("You %s a view once message.%s", verb, suffix)
350350
content = &event.MessageEventContent{
351351
MsgType: event.MsgNotice,
352352
Body: body,

pkg/msgconv/wa-media.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,12 +55,12 @@ func (mc *MessageConverter) convertMediaMessage(
5555
) (part *bridgev2.ConvertedMessagePart, contextInfo *waE2E.ContextInfo) {
5656
if mc.DisableViewOnce && isViewOnce {
5757
verb := "sent"
58-
extra := ""
58+
suffix := ""
5959
if !messageInfo.IsFromMe {
6060
verb = "received"
61-
extra = " For added privacy, you can only open it on the WhatsApp app."
61+
suffix = " For added privacy, you can only open it on the WhatsApp app."
6262
}
63-
body := fmt.Sprintf("You %s a view once %s.%s", verb, typeName, extra)
63+
body := fmt.Sprintf("You %s a view once %s.%s", verb, typeName, suffix)
6464
return &bridgev2.ConvertedMessagePart{
6565
Type: event.EventMessage,
6666
Content: &event.MessageEventContent{

0 commit comments

Comments
 (0)