Comments (3)
It already does (If i'm understanding you correctly). Look at these lines https://github.com/TheShadowGamer/Invite-Manager/blob/master/listeners/ready.js#L22-L26
client.guilds.cache.forEach(async guild => {
let invites = await guild.fetchInvites();
if(guild.vanityURLCode) invites.set(guild.vanityURLCode, await guild.fetchVanityData());
guildInvites.set(guild.id, invites);
});
from invite-manager.
I just downloaded again so everything was fresh, started the bot, commands work etc. but still says "has 0 invites!" but the user I mentioned has 5 invites according to the Discord Invites section, any idea why this would be happening?
(Bot accounts has required intents, is an admin in the server and the bot role is at the top of the role list)
from invite-manager.
Ah so that’s what you mean. My bad, I misunderstood you.
Discord does not track who invites who, which is the main point of the bot. So the bot has to track all that itself. Basically what the bot does is, when someone new joins it gets all the new invites and compares them with the old invites to find one where the old invites is less than the new. Now, this wouldn’t work if the bot is offline since it can’t know when a member joins, so that’s not fully possible. Someone suggested to store the old in a DB, and compare it to the new ones when the bot starts, but that wouldn’t work because their could have been more than one change.
tl;dr Not possible, can’t do anything. Look into a VPS for the bot to be up 24/7 and store invites fully, and it’ll start tracking from the moment you turn it on until you turn it off.
from invite-manager.
Related Issues (12)
- Dashboard HOT 18
- Slash Commands HOT 2
- how do i add to discord? HOT 1
- Welcome Channel HOT 1
- Single config per server HOT 1
- Where Do I Put The Token! HOT 2
- Create a Json File for welcome channel HOT 1
- Module not found HOT 2
- Replace role with required permission HOT 2
- [Bug] Leaderboard rankings are all "1" HOT 4
- invite reset doesn't work. HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from invite-manager.