mirror of
https://github.com/Vendicated/Vencord.git
synced 2025-02-25 07:48:32 +00:00
Fixed using globalname
This commit is contained in:
parent
a33106253c
commit
107140a4c1
1 changed files with 2 additions and 2 deletions
|
@ -44,11 +44,11 @@ async function showNotification(message: Message, guildId: string | undefined):
|
||||||
});
|
});
|
||||||
|
|
||||||
message.content = message.content.replace(userRegex, (match, userId: string) => {
|
message.content = message.content.replace(userRegex, (match, userId: string) => {
|
||||||
return `@${UserStore.getUser(userId)?.globalName}`;
|
return `@${(UserStore.getUser(userId) as any).globalName}`;
|
||||||
});
|
});
|
||||||
|
|
||||||
await Notifications.showNotification({
|
await Notifications.showNotification({
|
||||||
title: `${message.author.globalName} ${guildId ? `(#${channel?.name}, ${ChannelStore.getChannel(channel?.parent_id)?.name})` : ""}`,
|
title: `${(message.author as any).globalName} ${guildId ? `(#${channel?.name}, ${ChannelStore.getChannel(channel?.parent_id)?.name})` : ""}`,
|
||||||
body: message.content,
|
body: message.content,
|
||||||
icon: UserStore.getUser(message.author.id).getAvatarURL(undefined, undefined, false),
|
icon: UserStore.getUser(message.author.id).getAvatarURL(undefined, undefined, false),
|
||||||
onClick: function (): void {
|
onClick: function (): void {
|
||||||
|
|
Loading…
Add table
Reference in a new issue