decord/alpha/source/modules/messages/shouldRemoveSelfMention.tsx

28 lines
768 B
TypeScript
Raw Normal View History

2026-10-09 10:00:15 +00:00
// Module ID: 6087
// Function ID: 6088
2026-07-20 16:05:17 +00:00
// Name: shouldRemoveSelfMention
2026-10-03 08:58:59 +00:00
// Dependencies: [1085, 2]
2026-07-20 16:05:17 +00:00
// Exports: default
2026-10-09 10:00:15 +00:00
// Module 6087 (shouldRemoveSelfMention)
2026-10-03 08:58:59 +00:00
import Constants from "Constants" /* 1085 */;
import size from "module_2" /* 2 */;
2026-07-23 10:11:24 +00:00
const MessageTypesSets = Constants.MessageTypesSets;
const result = size.fileFinishedImporting("modules/messages/shouldRemoveSelfMention.tsx");
2026-07-20 16:05:17 +00:00
export default function shouldRemoveSelfMention(type, arg1) {
2026-07-20 16:05:17 +00:00
const SELF_MENTIONABLE_SYSTEM = MessageTypesSets.SELF_MENTIONABLE_SYSTEM;
2026-07-29 08:29:29 +00:00
const hasItem = SELF_MENTIONABLE_SYSTEM.has(type.type);
let tmp2 = !hasItem;
2026-10-03 08:58:59 +00:00
if (tmp2) {
2026-07-20 16:05:17 +00:00
const author = type.author;
let id;
2026-07-29 08:29:29 +00:00
if (author != null) {
2026-07-20 16:05:17 +00:00
id = author.id;
}
2026-07-29 08:29:29 +00:00
tmp2 = id === arg1;
2026-07-20 16:05:17 +00:00
}
2026-07-29 08:29:29 +00:00
return tmp2;
2026-07-20 16:05:17 +00:00
};