From 73e2d44c5519637f638e63104df310c2096215e9 Mon Sep 17 00:00:00 2001 From: Johannes Loher Date: Tue, 15 Feb 2022 21:57:21 +0100 Subject: [PATCH] refactor: use better types for rollMode --- src/rolls/check-factory.ts | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/rolls/check-factory.ts b/src/rolls/check-factory.ts index e020880d..dd475d6c 100644 --- a/src/rolls/check-factory.ts +++ b/src/rolls/check-factory.ts @@ -12,8 +12,7 @@ class DefaultCheckOptions implements DS4CheckFactoryOptions { readonly maximumCoupResult = 1; readonly minimumFumbleResult = 20; readonly useSlayingDice = false; - // TODO: Use the type `keyof CONFIG.Dice.rollModes` instead as soon as https://github.com/League-of-Foundry-Developers/foundry-vtt-types/issues/1501 has been resolved. - readonly rollMode: foundry.CONST.DICE_ROLL_MODES = "publicroll"; + readonly rollMode: keyof CONFIG.Dice.RollModes = "publicroll"; readonly flavor: undefined; mergeWith(other: Partial): DS4CheckFactoryOptions { @@ -198,7 +197,7 @@ function parseDialogFormData(formData: HTMLFormElement): Partial; speaker?: ReturnType;