mirror of
https://github.com/danbulant/discord.js
synced 2026-05-27 22:11:53 +00:00
Switch to User#tag in web builds example
This commit is contained in:
parent
3f7049e1a0
commit
95a531ee7d
1 changed files with 1 additions and 1 deletions
|
|
@ -30,7 +30,7 @@ The usage of the API isn't any different from using it in Node.js.
|
|||
client.on('message', msg => {
|
||||
const guildTag = msg.channel.type === 'text' ? `[${msg.guild.name}]` : '[DM]';
|
||||
const channelTag = msg.channel.type === 'text' ? `[#${msg.channel.name}]` : '';
|
||||
console.log(`${guildTag}${channelTag} ${msg.author.username}#${msg.author.discriminator}: ${msg.content}`);
|
||||
console.log(`${guildTag}${channelTag} ${msg.author.tag}: ${msg.content}`);
|
||||
});
|
||||
|
||||
client.login('some crazy token');
|
||||
|
|
|
|||
Loading…
Reference in a new issue