Skip to content

Commit

Permalink
Avoid ApplicativeDo
Browse files Browse the repository at this point in the history
  • Loading branch information
carlhammann committed Nov 1, 2023
1 parent 46b5e49 commit 4612740
Showing 1 changed file with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
{-# LANGUAGE ApplicativeDo #-}
{-# LANGUAGE DataKinds #-}
{-# LANGUAGE GADTs #-}
{-# LANGUAGE LambdaCase #-}
Expand Down Expand Up @@ -214,9 +213,9 @@ pCostModelsFile :: ShelleyBasedEra era -> Parser (Maybe (Cmd.CostModelsFile era)
pCostModelsFile =
caseShelleyToMaryOrAlonzoEraOnwards
(const $ pure Nothing)
( \alonzoOnwards -> do
file <- optional $ pCostModels (Just "new")
pure $ Cmd.CostModelsFile alonzoOnwards . File <$> file
( \alonzoOnwards ->
fmap (Cmd.CostModelsFile alonzoOnwards . File)
<$> optional (pCostModels (Just "new"))
)

pGovernanceActionProtocolParametersUpdateCmd :: ()
Expand Down

0 comments on commit 4612740

Please sign in to comment.