diff options
author | joe <joe@jerkface.net> | 2018-06-01 16:29:56 -0400 |
---|---|---|
committer | joe <joe@jerkface.net> | 2018-06-01 16:29:56 -0400 |
commit | 248c19df2a894db002f8c00301dcf755f926da4e (patch) | |
tree | 9654d6183f73157756a92d201ef99606b44244ac /Presence | |
parent | c788767dae5898a642f569ae2e73930ce05c2117 (diff) |
Remove ControlMaybe dependency from ConfigFiles.
Diffstat (limited to 'Presence')
-rw-r--r-- | Presence/ConfigFiles.hs | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/Presence/ConfigFiles.hs b/Presence/ConfigFiles.hs index 6354d841..5682ea94 100644 --- a/Presence/ConfigFiles.hs +++ b/Presence/ConfigFiles.hs | |||
@@ -13,7 +13,6 @@ import Control.Exception | |||
13 | import Control.Monad | 13 | import Control.Monad |
14 | import Control.DeepSeq | 14 | import Control.DeepSeq |
15 | import ByteStringOperators () -- For NFData instance | 15 | import ByteStringOperators () -- For NFData instance |
16 | import ControlMaybe | ||
17 | import Data.List (partition) | 16 | import Data.List (partition) |
18 | import Data.Maybe (catMaybes,isJust) | 17 | import Data.Maybe (catMaybes,isJust) |
19 | 18 | ||
@@ -100,12 +99,12 @@ modifyFile (tag,file) user profile test appending = configPath user profile file | |||
100 | withFile path WriteMode $ \h -> do | 99 | withFile path WriteMode $ \h -> do |
101 | L.hPutStrLn h tag | 100 | L.hPutStrLn h tag |
102 | forM_ (catMaybes keepers) (L.hPutStrLn h) | 101 | forM_ (catMaybes keepers) (L.hPutStrLn h) |
103 | withJust appending (L.hPutStrLn h) | 102 | forM_ appending (L.hPutStrLn h) |
104 | return . not . Prelude.null $ deleted | 103 | return . not . Prelude.null $ deleted |
105 | else do | 104 | else do |
106 | withFile path WriteMode $ \h -> do | 105 | withFile path WriteMode $ \h -> do |
107 | L.hPutStrLn h tag | 106 | L.hPutStrLn h tag |
108 | withJust appending (L.hPutStrLn h) | 107 | forM_ appending (L.hPutStrLn h) |
109 | return False | 108 | return False |
110 | 109 | ||
111 | modifySolicited, modifyBuddies, modifyOthers, modifyPending, modifySubscribers | 110 | modifySolicited, modifyBuddies, modifyOthers, modifyPending, modifySubscribers |