mirror of
https://github.com/danbulant/Shasha
synced 2026-05-24 12:22:00 +00:00
<:cathmmLife:772716381874946068>
This commit is contained in:
parent
6782fd30fa
commit
c48e72523b
1 changed files with 9 additions and 9 deletions
|
|
@ -14,7 +14,7 @@ module.exports = async (msgold, msgnew) => {
|
|||
if (msgnew.partial) msgnew = await msgnew.fetch();
|
||||
if (msgnew.partial) return;
|
||||
if (msgnew.content === msgold.content) return;
|
||||
const ignored = msgnew.guild.eventChannels.mesEd.ignore?.includes(msgnew.channel.id) ?? false;
|
||||
const ignored = msgnew.guild.eventChannels.mesEd?.ignore?.includes(msgnew.channel.id) || false;
|
||||
let check = false;
|
||||
if (msgnew.channel.id === msgnew.guild.eventChannels?.mesEd?.channel && msgnew.author ? msgnew.author !== msgnew.client.user : false && ignored === false) check = true;
|
||||
if (msgnew.guild.eventChannels?.mesEd?.channel !== msgnew.channel.id && ignored === false || check) {
|
||||
|
|
@ -22,14 +22,14 @@ module.exports = async (msgold, msgnew) => {
|
|||
if (!log || !msgnew.author) return;
|
||||
const emb = defaultEventLogEmbed(msgnew.guild);
|
||||
emb
|
||||
.setColor(getColor("blue"))
|
||||
.setDescription(msgnew.content.length > 0 ? msgnew.content : "`[EMPTY]`")
|
||||
.addField("Original content", msgold.content?.length > 0 ? (msgold.content.slice(0, msgold.content.length < 1025 ? 1024 : 1021) + (msgold.content.length < 1025 ? "" : "...")) : "`[EMPTY]`" )
|
||||
.setTitle("Message " + msgnew.id + " edited")
|
||||
.setAuthor(emb.author.name, msgnew.author.displayAvatarURL({format: "png", size: 128, dynamic: true}))
|
||||
.addField("Author", `<@!${msgnew.author?.id}>\n\`${msgnew.author?.tag}\`\n(${msgnew.author?.id})`,true)
|
||||
.addField("Channel", `<#${msgnew.channel?.id}>\n\`${msgnew.channel?.name}\`\n(${msgnew.channel?.id})`,true)
|
||||
.setURL(msgnew.url);
|
||||
.setColor(getColor("blue"))
|
||||
.setDescription(msgnew.content.length > 0 ? msgnew.content : "`[EMPTY]`")
|
||||
.addField("Original content", msgold.content?.length > 0 ? (msgold.content.slice(0, msgold.content.length < 1025 ? 1024 : 1021) + (msgold.content.length < 1025 ? "" : "...")) : "`[EMPTY]`")
|
||||
.setTitle("Message " + msgnew.id + " edited")
|
||||
.setAuthor(emb.author.name, msgnew.author.displayAvatarURL({ format: "png", size: 128, dynamic: true }))
|
||||
.addField("Author", `<@!${msgnew.author?.id}>\n\`${msgnew.author?.tag}\`\n(${msgnew.author?.id})`, true)
|
||||
.addField("Channel", `<#${msgnew.channel?.id}>\n\`${msgnew.channel?.name}\`\n(${msgnew.channel?.id})`, true)
|
||||
.setURL(msgnew.url);
|
||||
return trySend(msgnew.client, log, emb);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue