Housekeeping
This commit is contained in:
parent
3433674c41
commit
9901b3dc19
|
@ -33,7 +33,6 @@ module.exports = class FeedData {
|
|||
};
|
||||
}
|
||||
|
||||
/**@param guild*/
|
||||
updatePastPostedLinks(guild) {
|
||||
const channel = guild.channels.get(this.channelID);
|
||||
|
||||
|
@ -52,7 +51,6 @@ module.exports = class FeedData {
|
|||
});
|
||||
}
|
||||
|
||||
/**@param guild */
|
||||
fetchLatest(guild) {
|
||||
Dns.resolve(Url.parse(this.url).host || "", err => {
|
||||
if (err)
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
module.exports = class BaseGuildData {
|
||||
/**@param param */
|
||||
constructor(id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
|
|
@ -8,12 +8,6 @@ const HandleMessage = require("./HandleMessage.js");
|
|||
const InternalConfig = require("./internal-config.json");
|
||||
|
||||
module.exports = class Client extends Discord.Client {
|
||||
/**
|
||||
* @param {*} token
|
||||
* @param {*} dataFile
|
||||
* @param {*} commandsDir
|
||||
* @param {*} guildDataModel
|
||||
*/
|
||||
constructor(token, dataFile, commandsDir, guildDataModel) {
|
||||
super();
|
||||
|
||||
|
|
|
@ -1,5 +1,4 @@
|
|||
module.exports = class Command {
|
||||
/**@param param */
|
||||
constructor({ name, description, syntax, admin, invoke }) {
|
||||
this.name = name;
|
||||
this.description = description;
|
||||
|
|
|
@ -54,12 +54,6 @@ function handleInternalCommand(message, split, commands, isMemberAdmin) {
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a help embed for available commands
|
||||
* @param {string} name name of the bot
|
||||
* @param {*[]} commands commands array
|
||||
* @param {boolean} userIsAdmin whether the user is admin
|
||||
*/
|
||||
function createHelpEmbed(name, commands, userIsAdmin) {
|
||||
const commandsArr = Object.keys(commands).map(x => commands[x]).filter(x => userIsAdmin || !x.admin);
|
||||
|
||||
|
|
|
@ -1,15 +1,10 @@
|
|||
const Console = require("console");
|
||||
const Discord = require("discord.js");
|
||||
const SimpleFileWriter = require("simple-file-writer");
|
||||
|
||||
const logWriter = new SimpleFileWriter("./console.log");
|
||||
const debugLogWriter = new SimpleFileWriter("./debug.log");
|
||||
|
||||
/**
|
||||
* Returns a promise that the user will answer
|
||||
* @param {TextChannel} textChannel discord.js TextChannel to ask the question in
|
||||
* @param {GuildMember} member discord.js Member to ask the question to
|
||||
* @param {string} question question to ask
|
||||
*/
|
||||
function ask(client, textChannel, member, question) {
|
||||
//return a promise which will resolve once the user next sends a message in this textChannel
|
||||
return new Promise((resolve, reject) => {
|
||||
|
|
Loading…
Reference in New Issue