From d40527d0a2d9f209905750258f71bedff1cdf089 Mon Sep 17 00:00:00 2001 From: IRONM00N <64110067+IRONM00N@users.noreply.github.com> Date: Tue, 17 Aug 2021 12:31:09 -0400 Subject: turned on ts strict option --- src/commands/info/color.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/commands/info/color.ts') diff --git a/src/commands/info/color.ts b/src/commands/info/color.ts index 93dd439..350c23d 100644 --- a/src/commands/info/color.ts +++ b/src/commands/info/color.ts @@ -1,11 +1,11 @@ import { AllowedMentions, BushCommand, BushGuildMember, BushMessage, BushRole, BushSlashMessage } from '@lib'; import { Argument } from 'discord-akairo'; -import { MessageEmbed, Role } from 'discord.js'; +import { Message, MessageEmbed, Role } from 'discord.js'; import { Constructor } from 'tinycolor2'; // eslint-disable-next-line @typescript-eslint/no-var-requires const tinycolor: Constructor = require('tinycolor2'); // this is the only way I got it to work consistently -const isValidTinyColor = (_message: BushMessage, phase: string) => { +const isValidTinyColor = (_message: Message, phase: string) => { // if the phase is a number it converts it to hex incase it could be representing a color in decimal const newPhase = Number.isNaN(phase) ? phase : `#${Number(phase).toString(16)}`; return tinycolor(newPhase).isValid() ? newPhase : null; -- cgit