aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorSean Whitton <spwhitton@spwhitton.name>2017-02-28 21:55:16 -0700
committerSean Whitton <spwhitton@spwhitton.name>2017-02-28 21:55:16 -0700
commit67a213e550f82936dadf83918f40ff68f2cb51f9 (patch)
treede45d637f59a0d1df0949ac49101fc5f05f966e4
parent0f4a73c745602fc2a3f837e7c6e829eff44de68a (diff)
downloadsscan-67a213e550f82936dadf83918f40ff68f2cb51f9.tar.gz
Revert "rewrite ifScanSess"
-rw-r--r--Types/State.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Types/State.hs b/Types/State.hs
index 9d11019..5100c9a 100644
--- a/Types/State.hs
+++ b/Types/State.hs
@@ -101,7 +101,7 @@ data St =
makeLenses ''St
ifScanSess :: St -> a -> a -> a
-ifScanSess st a b = maybe b (const a) (st^.stScanSess)
+ifScanSess st a b = if isJust $ st^.stScanSess then a else b
-- | Update a state when there is no scanning session in progress (the
-- state should not be changed when some pages have already been