Tired of not finding a good warning system? Here you have the solution
Information
Discord Warns is a module that facilitates developers to improve their applications or bots
Dev: Esponjosin
INSTALLATION
To install we simply do
$ npm i discord-warns@latest
NOTE
All npm has been restructured and is now more modular, you can now interact more effectively with the data Update to 0.5.7 mandatory
USE
const Warns = const warns = dir: __dirname //If it is in discord you can do the warns by server adding an extra parameter called table, example const warns = dir: __dirname table: <guild>id
Datebase Functions
Create
Create is a function that allows you to create a user's base data if they do not exist
/*** @param*/ warns
Get
Get is a function that allows you to get base data from an id
/*** @param*/ warns
Delete
Delete is a function that deletes the data of an id
/*** @param*/ warns
All
All is a function that returns an array with all the data stored in the database
warnsall
Find
Find is a function that allows obtaining data outside the current table, it only works with the unique identifier
/*** @param*/ warns
Data Functions
Data is a constructor that is returned when getting / creating data from an id
Add
Add is a function that adds a warning
/*** @param {string/object} [moderator] - ID of the creator of the notice or User object of discord.js* @param*/ <Data>
Get
Get is a function that allows you to obtain the data of x warn
/*** @param*/ <Data>
Delete
Delete is a function that allows you to delete a notice using its unique identifier
/*** @param*/ <Data>