Simpleboy353 / REAPER-2.0

A multi-purpose discord bot made using Discord.js V14. Includes Logging, Welcomer, Slash Commands, Menu based Help Command and so much more!
GNU General Public License v3.0
329 stars 225 forks source link

Issue with Reaper when starting on Replit #158

Closed Nateay0 closed 2 years ago

Nateay0 commented 2 years ago

When I start Reaper on Replit I keep on getting this issue when doing node index Someone Please help 🥺 🙏

 node index
/home/runner/NBot/node_modules/discord.js/src/rest/RESTManager.js:32
    const token = this.client.token ?? this.client.accessToken;
                                     ^

SyntaxError: Unexpected token '?'
    at wrapSafe (internal/modules/cjs/loader.js:915:16)
    at Module._compile (internal/modules/cjs/loader.js:963:27)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/home/runner/NBot/node_modules/discord.js/src/client/BaseClient.js:4:21)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
 
Nateay0 commented 2 years ago

@Simpleboy353 Please help 🙏 🥺

davlix commented 2 years ago

Regenerate your bot token and add the new token to the config.json file

Simpleboy353 commented 2 years ago

When I start Reaper on Replit I keep on getting this issue when doing node index Someone Please help 🥺 🙏

 node index
/home/runner/NBot/node_modules/discord.js/src/rest/RESTManager.js:32
    const token = this.client.token ?? this.client.accessToken;
                                     ^

SyntaxError: Unexpected token '?'
    at wrapSafe (internal/modules/cjs/loader.js:915:16)
    at Module._compile (internal/modules/cjs/loader.js:963:27)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
    at Module.load (internal/modules/cjs/loader.js:863:32)
    at Function.Module._load (internal/modules/cjs/loader.js:708:14)
    at Module.require (internal/modules/cjs/loader.js:887:19)
    at require (internal/modules/cjs/helpers.js:74:18)
    at Object.<anonymous> (/home/runner/NBot/node_modules/discord.js/src/client/BaseClient.js:4:21)
    at Module._compile (internal/modules/cjs/loader.js:999:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1027:10)
 

You need to update node to v16 in replit, follow these instructions:

How to fix the Unexpected Token "?"error?

Nateay0 commented 2 years ago

Still won't work 😢

Simpleboy353 commented 2 years ago

where did you run this code?

Nateay0 commented 2 years ago

On Replit

Nateay0 commented 2 years ago

I can share the link so you can edit my replit if u want

Simpleboy353 commented 2 years ago

Share in dm in discord

Nateay0 commented 2 years ago

I just did

Nateay0 commented 2 years ago

I sent the Replit link to your discord