From a7e923cba4dea3d5e0aaf03081d8d3266681c8d5 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Thu, 4 Feb 2016 19:04:07 +0000 Subject: Fixed type ambiguity --- server/src/Thermoprint/Server/API.hs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'server/src') diff --git a/server/src/Thermoprint/Server/API.hs b/server/src/Thermoprint/Server/API.hs index 2433c8e..247fb89 100644 --- a/server/src/Thermoprint/Server/API.hs +++ b/server/src/Thermoprint/Server/API.hs @@ -146,11 +146,11 @@ listJobs :: Maybe PrinterId listJobs Nothing minId maxId minTime maxTime = fmap mconcat . mapM (\pId -> listJobs (Just pId) minId maxId minTime maxTime) =<< asks (Map.keys . printers) listJobs pId minId maxId minTime maxTime = fmap (filterJobs . extractJobs) . (\(a, b) -> (,) a <$> queue' b) =<< lookupPrinter pId where - filterJobs = Seq.filter (\(id, time, _) -> and [ maybe True (<= id ) minId - , maybe True (>= id ) maxId - , maybe True (<= time) minTime - , maybe True (>= time) maxTime - ] + filterJobs = Seq.filter (\(id, time, _) -> and ([ maybe True (<= id ) minId + , maybe True (>= id ) maxId + , maybe True (<= time) minTime + , maybe True (>= time) maxTime + ] :: [Bool]) ) getJob :: API.JobId -> Handler Printout -- cgit v1.2.3