From 9f971cb15913f6d3e2018cdd3153d0611804d090 Mon Sep 17 00:00:00 2001 From: Willem Van Onsem Date: Mon, 15 Mar 2021 23:45:26 +0100 Subject: [PATCH] remove redundant brackets in Game.hs --- src/UI/Game.hs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/UI/Game.hs b/src/UI/Game.hs index e62e55e..315c9bf 100644 --- a/src/UI/Game.hs +++ b/src/UI/Game.hs @@ -163,7 +163,7 @@ drawGrid ui = $ mconcat [ drawBlockCell NormalBlock <$> ui ^. game ^. board , blockMap NormalBlock (ui ^. game ^. block) - , case (ui ^. preview) of + , case ui ^. preview of Nothing -> M.empty Just s -> blockMap (HardDropBlock s) (evalTetris hardDroppedBlock (ui ^. game)) , emptyCellMap @@ -174,7 +174,7 @@ drawGrid ui = emptyCellMap :: Map Coord (Widget Name) emptyCellMap = M.fromList - [ ((V2 x y), emptyGridCellW) | x <- [1 .. boardWidth], y <- [1 .. boardHeight] ] + [ (V2 x y, emptyGridCellW) | x <- [1 .. boardWidth], y <- [1 .. boardHeight] ] emptyGridCellW :: Widget Name emptyGridCellW = withAttr emptyAttr cw @@ -275,7 +275,7 @@ drawKeyInfo action keys = drawGameOver :: Game -> Widget Name drawGameOver g = - if (isGameOver g) + if isGameOver g then padLeftRight 4 $ withAttr gameOverAttr $ str "GAME OVER" else emptyWidget