Uncaught Promise Error: TypeError: Cannot read property 'prototype' of undefined

Hey @TheBigerGamer, here’s what I think is going on.

Klasa is, unfortnately, not a drop-in replacement for Komada, so your Komada objects need to be modified to work properly with Klasa. Here’s one example:

Komada Command objects are expected to export a run function and optional conf and help properties. This is the model that your commands are following, for example https://glitch.com/edit/#!/warlock-gaming-bot?path=commands/Fun/Interactions/8ball.js.

Klasa Command objects, on the other hand, are constructed differently. They’re expected to export a class that extends the Klasa base object and that includes its configuration in the constructor function and also to have a run function and an optional init function.

So in short, you’ll need to change up all your commands to use the new format of the Klasa objects as shown in the Klasa documents. This explains why your logs are filled with messages like this

[2019-02-27 18:16:34] TypeError: Exported Structure Not A Class
[2019-02-27 18:16:34] /app/commands/Fun/Interactions/8ball.js

Basically that’s Klasa saying “you told me to load something called 8ball but when I tried to do that it wasn’t a class like I expected”.

That also, at least on the surface, might explain the other error; Klasa was trying to use a property of something that it couldn’t load (and which is, therefore, “undefined”).

The Klasa GitHub repo has sample implementation of some of the same commands you’re using. For example, this is their implementation of the 8ball command you have. Those might help you make the switch.

I’ll also second what @Callum-OKane said; because your project is public (which is important for not-Glitch-staff to be able to help) and because your token is in a public file, your bot’s token’s been seen by anyone who’s looked at your project and you should revoke it ASAP and get another one. If you want to keep your project public so you can continue to rely on the community for help, you can put the new token in your .env file, maybe in a variable called TOKEN. Then in your bot code, after you require() the other data in your config file, you could use config.token = process.env.TOKEN;. This will mean that folks can see (but not edit) the majority of your bot’s code, and offer specific suggestions to problems you run into, while not being able to see your secrets in your .env file (only a few Glitch staff members and people you specifically invite using the Share options will be able to read that).

Hope this helps, and happy Glitching!