重构猜谜活动并统一聊天室答题通知
This commit is contained in:
@@ -478,12 +478,21 @@ export function resolveBlockedSystemSenderKey(msg) {
|
||||
const content = String(msg?.content || "");
|
||||
const action = String(msg?.action || "");
|
||||
const idiomRoundId = Number.parseInt(
|
||||
String(msg?.idiom_game_round_id || msg?.idom_game_round_id || msg?.idiom_game_round_ended_id || "0"),
|
||||
String(msg?.quiz_round_id || msg?.idiom_game_round_id || msg?.idom_game_round_id || msg?.quiz_round_ended_id || msg?.idiom_game_round_ended_id || "0"),
|
||||
10,
|
||||
);
|
||||
const quizType = String(msg?.quiz_type || "");
|
||||
const quizTypeLabel = String(msg?.quiz_type_label || "");
|
||||
|
||||
// 猜成语消息独立作为一个通知类型管理,不再复用“星海小博士”的屏蔽规则。
|
||||
if (idiomRoundId > 0 || action === "idiom_result" || (fromUser === "星海小博士" && content.includes("猜成语"))) {
|
||||
// 猜谜活动消息独立作为一个通知类型管理,不再复用“星海小博士”的屏蔽规则。
|
||||
if (
|
||||
idiomRoundId > 0 ||
|
||||
action === "idiom_result" ||
|
||||
quizType === "idiom" ||
|
||||
quizTypeLabel.includes("成语") ||
|
||||
(fromUser === "星海小博士" && (content.includes("猜成语") || content.includes("猜谜活动"))) ||
|
||||
((fromUser === "系统传音" || fromUser === "系统") && (content.includes("猜成语") || content.includes("猜谜活动")))
|
||||
) {
|
||||
return "猜成语";
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user