mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-10 16:14:58 +00:00
fix(telegram): fail closed on empty group allowFrom override
This commit is contained in:
committed by
Ayaan Zaidi
parent
81752564e9
commit
6bc7544a6a
@@ -813,6 +813,29 @@ describe("createTelegramBot", () => {
|
||||
},
|
||||
expectedReplyCount: 1,
|
||||
},
|
||||
{
|
||||
name: "blocks group messages when per-group allowFrom override is explicitly empty",
|
||||
config: {
|
||||
channels: {
|
||||
telegram: {
|
||||
groupPolicy: "open",
|
||||
groups: {
|
||||
"-100123456789": {
|
||||
allowFrom: [],
|
||||
requireMention: false,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
message: {
|
||||
chat: { id: -100123456789, type: "group", title: "Test Group" },
|
||||
from: { id: 999999, username: "random" },
|
||||
text: "hello",
|
||||
date: 1736380800,
|
||||
},
|
||||
expectedReplyCount: 0,
|
||||
},
|
||||
{
|
||||
name: "allows all group messages when groupPolicy is 'open'",
|
||||
config: {
|
||||
|
||||
Reference in New Issue
Block a user