From f39658603373ebd4253907da8feb557df2321ebd Mon Sep 17 00:00:00 2001 From: Rnhmjoj Date: Fri, 17 Oct 2014 00:13:48 +0200 Subject: [PATCH] New version 0.2.1 Fixes --- alea.cabal | 2 +- main.hs | 7 +++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/alea.cabal b/alea.cabal index 812e0e4..038bc20 100644 --- a/alea.cabal +++ b/alea.cabal @@ -1,5 +1,5 @@ name: alea -version: 0.2.0.0 +version: 0.2.1.0 synopsis: a diceware passphrase generator description: diff --git a/main.hs b/main.hs index b6e85c1..ba33688 100644 --- a/main.hs +++ b/main.hs @@ -59,7 +59,6 @@ exec args@Args{..} = randWords dictSize phraseLength >>= putStrLn . unwords . map dice' when (phrases > 1) $ exec args {phrases = phrases - 1} where - -- helpers - dice n = readDiceware (parseDiceware dictionary) (read n :: Int) - dice' n = readDiceware' (parseDiceware dictionary) n - dictSize = length $ parseDiceware dictionary + (dict, dictSize) = (parseDiceware dictionary, length dict) + dice n = readDiceware dict (read n :: Int) + dice' n = readDiceware' dict n