Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const Discord = require('discord.js');
- const client = new Discord.Client();
- const channelId = 'الاي دي';
- //حط اي دي الاتشانل
- client.on('ready', () => {
- console.log(`Logged in as ${client.user.tag}`);
- });
- client.on('error', (error) => {
- console.error('Discord client error:', error);
- const channel = client.channels.cache.get(channelId);
- if (channel) {
- channel.send(`An error occurred: \`${error}\``);
- }
- });
- client.login(process.env.token)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement