From 570cfe4af2e9a92006baa4ff6cd476e704425c23 Mon Sep 17 00:00:00 2001 From: Jonathan Lamothe Date: Fri, 21 Dec 2018 16:44:25 -0500 Subject: [PATCH] fixed nextPolicy (for serious this time) --- src/Password.hs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Password.hs b/src/Password.hs index 026c6ff..933b383 100644 --- a/src/Password.hs +++ b/src/Password.hs @@ -231,7 +231,7 @@ nextPolicy x p = over pwLength pred $ then dec pwDigits else case p^.pwSpecial of Nothing -> set pwSpecial (Just (-1)) p - Just x -> set pwSpecial (Just $ pred x) p + Just _ -> dec $ pwSpecial . traverse where dec l = over l (max 0 . pred) p