Skip to content

Use interaction.createdTimestamp instead of Date.now() in Cooldowns guide section #1466

Open
@Sn4red

Description

@Sn4red

Is your feature request related to a problem? Please describe.

If a user has a different/wrong time, it can cause an error in the cooldown since Date.now() retrieves the current timestamp from the computer where the bot is running, not from the user executing it, resulting in a potential variation in the cooldown.

Describe the solution you'd like

Using interaction.createdTimestamp can solve the problem and would be more informative for the guide, especially if someone tries the code with others.

Describe alternatives you've considered

No response

Additional notes

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    t: requestSuggestion to add new or change existing content

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions