welcome message: point updates-channel mention at @ziodotsh
Rename the official updates channel mention from @zio to @ziodotsh in the welcome message template and update the affected send-message test.
This commit is contained in:
parent
b047a90271
commit
c8380b4257
2 changed files with 7 additions and 6 deletions
|
|
@ -16,7 +16,7 @@ import (
|
||||||
// render it as a tappable link; the mention itself lives in the default
|
// render it as a tappable link; the mention itself lives in the default
|
||||||
// templates in login_welcome_template.go (or an admin-panel override), not
|
// templates in login_welcome_template.go (or an admin-panel override), not
|
||||||
// hardcoded here.
|
// hardcoded here.
|
||||||
const officialUpdatesChannelMention = "@zio"
|
const officialUpdatesChannelMention = "@ziodotsh"
|
||||||
|
|
||||||
// OfficialWelcomeMessage builds the account-visible incoming message sent
|
// OfficialWelcomeMessage builds the account-visible incoming message sent
|
||||||
// from the official system account on every completed sign-in (SignUp and
|
// from the official system account on every completed sign-in (SignUp and
|
||||||
|
|
|
||||||
|
|
@ -2,10 +2,6 @@ package rpc
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"context"
|
"context"
|
||||||
"github.com/iamxvbaba/td/clock"
|
|
||||||
"github.com/iamxvbaba/td/proto"
|
|
||||||
"github.com/iamxvbaba/td/tg"
|
|
||||||
"go.uber.org/zap/zaptest"
|
|
||||||
"strings"
|
"strings"
|
||||||
appchannels "telesrv/internal/app/channels"
|
appchannels "telesrv/internal/app/channels"
|
||||||
appupdates "telesrv/internal/app/updates"
|
appupdates "telesrv/internal/app/updates"
|
||||||
|
|
@ -13,6 +9,11 @@ import (
|
||||||
"telesrv/internal/domain"
|
"telesrv/internal/domain"
|
||||||
"telesrv/internal/store/memory"
|
"telesrv/internal/store/memory"
|
||||||
"testing"
|
"testing"
|
||||||
|
|
||||||
|
"github.com/iamxvbaba/td/clock"
|
||||||
|
"github.com/iamxvbaba/td/proto"
|
||||||
|
"github.com/iamxvbaba/td/tg"
|
||||||
|
"go.uber.org/zap/zaptest"
|
||||||
)
|
)
|
||||||
|
|
||||||
func TestChannelRealtimeRecipientsPreferOnlineMembers(t *testing.T) {
|
func TestChannelRealtimeRecipientsPreferOnlineMembers(t *testing.T) {
|
||||||
|
|
@ -662,7 +663,7 @@ func TestChannelSendMessageWithUnresolvableMentionSucceeds(t *testing.T) {
|
||||||
t.Fatalf("create megagroup: %v", err)
|
t.Fatalf("create megagroup: %v", err)
|
||||||
}
|
}
|
||||||
peer := &tg.InputPeerChannel{ChannelID: created.Channel.ID, AccessHash: created.Channel.AccessHash}
|
peer := &tg.InputPeerChannel{ChannelID: created.Channel.ID, AccessHash: created.Channel.AccessHash}
|
||||||
for i, text := range []string{"look at @zio", "hi @2cool and @_x"} {
|
for i, text := range []string{"look at @ziodotsh", "hi @2cool and @_x"} {
|
||||||
if _, err := r.onMessagesSendMessage(WithUserID(ctx, owner.ID), &tg.MessagesSendMessageRequest{
|
if _, err := r.onMessagesSendMessage(WithUserID(ctx, owner.ID), &tg.MessagesSendMessageRequest{
|
||||||
Peer: peer,
|
Peer: peer,
|
||||||
Message: text,
|
Message: text,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue