3
0
Fork 0
mirror of https://github.com/ZeppelinBot/Zeppelin.git synced 2025-05-13 21:35:02 +00:00

fix(logs): fix inconsistent thread/channel/category exclusions; add excluded_threads log channel option

This commit is contained in:
Dragory 2022-08-13 23:19:06 +03:00
parent 218c31231e
commit d472fd4fa6
No known key found for this signature in database
GPG key ID: 5F387BA66DF8AAC1
32 changed files with 132 additions and 51 deletions
backend/src/plugins/Logs/logFunctions

View file

@ -11,6 +11,7 @@ import {
} from "../../../utils/templateSafeObjects";
import { SavedMessage } from "../../../data/entities/SavedMessage";
import { UnknownUser } from "../../../utils";
import { resolveChannelIds } from "../../../utils/resolveChannelIds";
interface LogMessageEditData {
user: User | UnknownUser;
@ -31,9 +32,9 @@ export function logMessageEdit(pluginData: GuildPluginData<LogsPluginType>, data
}),
{
userId: data.user.id,
channel: data.channel.id,
messageTextContent: data.after.data.content,
bot: data.user instanceof User ? data.user.bot : false,
...resolveChannelIds(data.channel),
},
);
}