diff options
author | Joey Hess <joey@kitenet.net> | 2011-05-15 02:49:43 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2011-05-15 03:38:08 -0400 |
commit | cad0e1c8b7eb21f8dceca8dd9fa3bc1d1aa7eabd (patch) | |
tree | b6be12dc1cc83a35ca7d89a862d85e6d71c38572 /LocationLog.hs | |
parent | efa7f544050c0d5be6bc1b0fc0125278e475c213 (diff) |
simplified a bunch of Maybe handling
Diffstat (limited to 'LocationLog.hs')
-rw-r--r-- | LocationLog.hs | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/LocationLog.hs b/LocationLog.hs index e0ccb642b..6759b47fe 100644 --- a/LocationLog.hs +++ b/LocationLog.hs @@ -71,9 +71,7 @@ instance Read LogLine where -- Such lines have a status of Undefined. readsPrec _ string = if length w == 3 - then case pdate of - Just v -> good v - Nothing -> bad + then maybe bad good pdate else bad where w = words string |