From 9d9c3e075a7cfc2aa6211b62eae0064f272a91c0 Mon Sep 17 00:00:00 2001 From: "alxjrvs@gmail.com" Date: Thu, 7 Nov 2024 16:49:15 -0500 Subject: [PATCH] Remove unused default --- src/models/ArgumentsModel.ts | 4 ++-- src/models/DicePoolsModel.ts | 8 ++++---- src/models/OptionsModel/index.ts | 2 +- src/models/ParametersModel/index.ts | 4 ++-- src/roll.ts | 2 +- 5 files changed, 10 insertions(+), 10 deletions(-) diff --git a/src/models/ArgumentsModel.ts b/src/models/ArgumentsModel.ts index e6fa8b44..f4a8bcf4 100644 --- a/src/models/ArgumentsModel.ts +++ b/src/models/ArgumentsModel.ts @@ -4,7 +4,7 @@ import { isD, isDicePoolOptions, isDiceNotationArg } from '~guards' import { NotationModel, OptionsModel } from '~models' import { D } from '~src/D' -function formDicePools( +function formDicePools( args: RollArgument[] ): DicePools { return { @@ -36,7 +36,7 @@ function parameterize(argument: RollArgument): RollParameters function parameterize( argument: RollArgument ): RollParameters -function parameterize( +function parameterize( argument: RollArgument ): RollParameters { const options = toOptions(argument) diff --git a/src/models/DicePoolsModel.ts b/src/models/DicePoolsModel.ts index 79ddb396..9b8fe0d4 100644 --- a/src/models/DicePoolsModel.ts +++ b/src/models/DicePoolsModel.ts @@ -21,7 +21,7 @@ function calculateType( } } -function calculateTotal( +function calculateTotal( rolls: Sides[], bonus = 0 ): Sides { @@ -35,7 +35,7 @@ function calculateTotal( return rolls.flat().join(', ') as Sides } -function generateModifiedRolls( +function generateModifiedRolls( DicePools: DicePools, rawRolls: RollResult['rawRolls'] ): RollResult['modifiedRolls'] { @@ -52,7 +52,7 @@ function generateModifiedRolls( ) as RollResult['modifiedRolls'] } -function generateRawRolls( +function generateRawRolls( dicePools: DicePools['dicePools'] ): RollResult['rawRolls'] { return Object.fromEntries( @@ -66,7 +66,7 @@ function generateRawRolls( ) } -function generateRollResult( +function generateRollResult( dicePools: DicePools ): RollResult { const rawRolls = generateRawRolls(dicePools.dicePools) diff --git a/src/models/OptionsModel/index.ts b/src/models/OptionsModel/index.ts index 0fb605cf..f4cba012 100644 --- a/src/models/OptionsModel/index.ts +++ b/src/models/OptionsModel/index.ts @@ -8,7 +8,7 @@ import { formatModifierDescriptions } from './stringFormatters' -function toNotation( +function toNotation( options: RollOptions ): Notation { return `${formatCoreNotation(options)}${formatModifierNotation(options)}` as Notation diff --git a/src/models/ParametersModel/index.ts b/src/models/ParametersModel/index.ts index 179f23b7..ec25e4ab 100644 --- a/src/models/ParametersModel/index.ts +++ b/src/models/ParametersModel/index.ts @@ -9,12 +9,12 @@ import { applySingleCap } from './modifierApplicators' -type RollBonuses = { +type RollBonuses = { rolls: Sides[] simpleMathModifier: number } -function applyModifiers( +function applyModifiers( poolParameters: RollParameters, initialRolls: Sides[] ): RollBonuses { diff --git a/src/roll.ts b/src/roll.ts index bfe87cb9..7277b2f3 100644 --- a/src/roll.ts +++ b/src/roll.ts @@ -12,7 +12,7 @@ import { function roll(...args: NumericalArgument[]): NumericalRollResult function roll(...args: CustomArgument[]): CustomRollResult function roll(...args: RollArgument[]): MixedRollResult -function roll( +function roll( ...args: RollArgument[] ): RollResult { const dicePools = ArgumentsModel.formDicePools(args)