pull/29/head
Matthew 2020-11-08 00:59:56 -05:00
parent 67e5dd2826
commit 152b78b2ea
No known key found for this signature in database
GPG Key ID: 210AF32ADE3B5C4B
3 changed files with 3 additions and 14 deletions

View File

@ -25,7 +25,7 @@ export default class Score_Hist extends Command {
user = message.author; user = message.author;
if (!user) return this.error(message.channel, 'Member not found.'); if (!user) return this.error(message.channel, 'Member not found.');
const hists = await this.client.db.ScoreHistorical.find({ userID: user.id }).lean().exec(); const hists = await this.client.db.ScoreHistorical.find({ userID: user.id }).lean().exec();
if (!hists) return this.error(message.channel, 'No history found.'); if (!hists || hists?.length <= 0) return this.error(message.channel, 'No history found.');
const histArray: [{ name: string, value: string }?] = []; const histArray: [{ name: string, value: string }?] = [];
const totalArray: number[] = []; const totalArray: number[] = [];
const activityArray: number[] = []; const activityArray: number[] = [];

View File

@ -1,6 +1,5 @@
import { Message } from 'eris'; import { Message } from 'eris';
import { Client, Command } from '../class'; import { Client, Command } from '../class';
import Score_Hist from './score_hist';
export default class Score_Notify extends Command { export default class Score_Notify extends Command {
constructor(client: Client) { constructor(client: Client) {
@ -8,7 +7,6 @@ export default class Score_Notify extends Command {
this.name = 'notify'; this.name = 'notify';
this.description = 'Edits your notification preferences for Hard Inquiries.'; this.description = 'Edits your notification preferences for Hard Inquiries.';
this.usage = `${this.client.config.prefix}score notify <on | off>`; this.usage = `${this.client.config.prefix}score notify <on | off>`;
this.subcmds = [Score_Hist];
this.permissions = 0; this.permissions = 0;
this.guildOnly = false; this.guildOnly = false;
this.enabled = true; this.enabled = true;

View File

@ -1,13 +1,5 @@
/* eslint-disable no-continue */ import { Message } from 'eris';
/* eslint-disable default-case */ import { Client, Command } from '../class';
import moment from 'moment';
import { median, mode, mean } from 'mathjs';
import { v4 as uuid } from 'uuid';
import { createPaginationEmbed } from 'eris-pagination';
import { Message, User, TextChannel } from 'eris';
import { Client, Command, RichEmbed } from '../class';
import Score_Hist from './score_hist';
import Score_Notify from './score_notify';
export default class Score_Pref extends Command { export default class Score_Pref extends Command {
constructor(client: Client) { constructor(client: Client) {
@ -15,7 +7,6 @@ export default class Score_Pref extends Command {
this.name = 'pref'; this.name = 'pref';
this.description = 'Locks or unlocks your Community Report.'; this.description = 'Locks or unlocks your Community Report.';
this.usage = `${this.client.config.prefix}score pref <lock | unlock>`; this.usage = `${this.client.config.prefix}score pref <lock | unlock>`;
this.subcmds = [Score_Hist, Score_Notify];
this.permissions = 0; this.permissions = 0;
this.guildOnly = false; this.guildOnly = false;
this.enabled = true; this.enabled = true;