How can i do this? Please help!

Tell us what’s happening:
Describe your issue in detail here.

Every time it brings up an error saying in discord.js

''RangeError [BITFIELD_INVALID]: Invalid bitfield flag or number: GUILD.
    at Function.resolve (/home/runner/Sir-issac/node_modules/discord.js/src/util/BitField.js:152:11)
    at /home/runner/Sir-issac/node_modules/discord.js/src/util/BitField.js:147:54
    at (<anonymous>)
    at Function.resolve (/home/runner/Sir-issac/node_modules/discord.js/src/util/BitField.js:147:40)
    at Client._validateOptions (/home/runner/Sir-issac/node_modules/discord.js/src/client/Client.js:550:33)
    at new Client (/home/runner/Sir-issac/node_modules/discord.js/src/client/Client.js:76:10)
    at Object.<anonymous> (/home/runner/Sir-issac/index.js:2:13)
    at Module._compile (node:internal/modules/cjs/loader:1101:14)
  **Your code so far**
const djs = require('discord.js');
const bot = new djs.Client({
  intents: [
const config = process.env;

bot.on('ready', () => {
  console.log(bot.user.username + 'is online!')

  **Your browser information:**

User Agent is: Mozilla/5.0 (X11; CrOS x86_64 14268.83.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.208 Safari/537.36

Challenge: Step 12

Link to the challenge:

The intent string is GUILDS not GUILD :slightly_smiling_face:

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.