mirror of
https://github.com/JonnyBro/JaBa.git
synced 2024-11-22 05:04:58 +05:00
fix quote generation
This commit is contained in:
parent
6e7ade5da7
commit
677bcce92a
1 changed files with 3 additions and 2 deletions
|
@ -48,8 +48,9 @@ class MessageCreate extends BaseEvent {
|
||||||
await updateXp(client, message, data);
|
await updateXp(client, message, data);
|
||||||
|
|
||||||
if (message.content.includes("discord.com/channels/")) {
|
if (message.content.includes("discord.com/channels/")) {
|
||||||
const ids = message.content.match(/\d+/g);
|
const link = message.content.match(/(https|http):\/\/(discord.com)\/(channels)\/\d+\/\d+\/\d+/g)[0],
|
||||||
const channelId = ids[1],
|
ids = link.match(/\d+/g),
|
||||||
|
channelId = ids[1],
|
||||||
messageId = ids[2];
|
messageId = ids[2];
|
||||||
|
|
||||||
const msg = await client.channels.cache.get(channelId).messages.fetch(messageId);
|
const msg = await client.channels.cache.get(channelId).messages.fetch(messageId);
|
||||||
|
|
Loading…
Reference in a new issue