import { GuildMember } from "discord.js" export const name = 'guildMemberUpdate' export async function execute(oldMember: GuildMember, newMember: GuildMember) { try { console.log(`User ${oldMember.displayName} has been updated`) console.log(`OldRoles: ${JSON.stringify(oldMember.roles.cache.map(x => x.name))}`) console.log(`NewRoles: ${JSON.stringify(newMember.roles.cache.map(x => x.name))}`) } catch (error) { console.error(error) } }