diff options
author | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-08-17 12:31:09 -0400 |
---|---|---|
committer | IRONM00N <64110067+IRONM00N@users.noreply.github.com> | 2021-08-17 12:31:09 -0400 |
commit | d40527d0a2d9f209905750258f71bedff1cdf089 (patch) | |
tree | e017fd844c2135bfc85228d00ef2617d24ce0a3f /src/arguments | |
parent | d431ad00754f3f250103deedea495b9bcee73fc0 (diff) | |
download | tanzanite-d40527d0a2d9f209905750258f71bedff1cdf089.tar.gz tanzanite-d40527d0a2d9f209905750258f71bedff1cdf089.tar.bz2 tanzanite-d40527d0a2d9f209905750258f71bedff1cdf089.zip |
turned on ts strict option
Diffstat (limited to 'src/arguments')
-rw-r--r-- | src/arguments/contentWithDuration.ts | 2 | ||||
-rw-r--r-- | src/arguments/permission.ts | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/arguments/contentWithDuration.ts b/src/arguments/contentWithDuration.ts index 99b251f..314b761 100644 --- a/src/arguments/contentWithDuration.ts +++ b/src/arguments/contentWithDuration.ts @@ -3,6 +3,6 @@ import { BushArgumentTypeCaster, BushMessage } from '@lib'; export const contentWithDurationTypeCaster: BushArgumentTypeCaster = async ( _message: BushMessage, phrase: string -): Promise<{ duration: number; contentWithoutTime: string }> => { +): Promise<{ duration: number; contentWithoutTime: string | null }> => { return client.util.parseDuration(phrase); }; diff --git a/src/arguments/permission.ts b/src/arguments/permission.ts index dc90f3a..8ad0102 100644 --- a/src/arguments/permission.ts +++ b/src/arguments/permission.ts @@ -4,7 +4,7 @@ import { BushArgumentTypeCaster } from '../lib/extensions/discord-akairo/BushArg export const permissionTypeCaster: BushArgumentTypeCaster = (_, phrase) => { if (!phrase) return null; phrase = phrase.toUpperCase().replace(/ /g, '_'); - if (!Permissions.FLAGS[phrase]) { + if (!Permissions.FLAGS[phrase as keyof typeof Permissions.FLAGS]) { return null; } else { return phrase; |