Fix note custom log
This commit is contained in:
@@ -7,6 +7,8 @@ export default {
|
|||||||
handler: async function (client: Client, interaction: ModalSubmitInteraction, id: string) {
|
handler: async function (client: Client, interaction: ModalSubmitInteraction, id: string) {
|
||||||
const message = interaction.fields.getTextInputValue('note-message');
|
const message = interaction.fields.getTextInputValue('note-message');
|
||||||
|
|
||||||
|
const user = await client.users.fetch(id);
|
||||||
|
|
||||||
logCustomEvent(interaction.guild!, {
|
logCustomEvent(interaction.guild!, {
|
||||||
title: 'Note Added',
|
title: 'Note Added',
|
||||||
description: null,
|
description: null,
|
||||||
@@ -14,10 +16,15 @@ export default {
|
|||||||
timestamp: new Date(),
|
timestamp: new Date(),
|
||||||
fields: [
|
fields: [
|
||||||
{
|
{
|
||||||
name: 'User',
|
name: 'Moderator',
|
||||||
value: `<@${interaction.user.id}>\n${interaction.user.username}`,
|
value: `<@${interaction.user.id}>\n${interaction.user.username}`,
|
||||||
inline: true
|
inline: true
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: 'User',
|
||||||
|
value: `<@${id}>\n${user.username}`,
|
||||||
|
inline: true
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: 'Note',
|
name: 'Note',
|
||||||
value: message,
|
value: message,
|
||||||
|
|||||||
Reference in New Issue
Block a user