Giter Site home page Giter Site logo

Comments (3)

TheShadowGamer avatar TheShadowGamer commented on September 7, 2024

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.

VenomTR avatar VenomTR commented on September 7, 2024

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.

TheShadowGamer avatar TheShadowGamer commented on September 7, 2024

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)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.