refactor: sync sparse tlprofile runtime

This commit is contained in:
A 2026-07-16 21:36:32 +08:00
parent 5ecf4e912d
commit 25ab04a254
93 changed files with 2983 additions and 1615 deletions

View file

@ -64,12 +64,8 @@ func TestChannelsDeleteChannelCascadesMonoforumForbiddenRPC(t *testing.T) {
if err != nil {
t.Fatalf("dispatch get dialogs: %v", err)
}
box, ok := enc.(*tg.MessagesDialogsBox)
if !ok {
t.Fatalf("dialogs response = %T, want box", enc)
}
ids := map[int64]struct{}{}
switch d := box.Dialogs.(type) {
switch d := enc.(type) {
case *tg.MessagesDialogs:
for _, ch := range d.Chats {
if c, ok := ch.(*tg.Channel); ok {
@ -83,7 +79,7 @@ func TestChannelsDeleteChannelCascadesMonoforumForbiddenRPC(t *testing.T) {
}
}
default:
t.Fatalf("dialogs = %T, want messages.dialogs(Slice)", box.Dialogs)
t.Fatalf("dialogs = %T, want messages.dialogs(Slice)", enc)
}
return ids
}