summaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorJose Antonio Ortega Ruiz <jao@gnu.org>2011-01-15 00:50:18 +0100
committerJose Antonio Ortega Ruiz <jao@gnu.org>2011-01-15 00:50:18 +0100
commitafc503e0697046029a5fcbdfe313cbba302b8421 (patch)
tree336f7445e6f5cdbd0450a82327ea5bd30437e36c
parent9d9ae4166bd0d6b85f1eb19d6f1699a6453517db (diff)
downloadxmobar-afc503e0697046029a5fcbdfe313cbba302b8421.tar.gz
xmobar-afc503e0697046029a5fcbdfe313cbba302b8421.tar.bz2
Linting
-rw-r--r--src/Plugins/Monitors/Volume.hs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/Plugins/Monitors/Volume.hs b/src/Plugins/Monitors/Volume.hs
index 0c5f92c..50a6ed4 100644
--- a/src/Plugins/Monitors/Volume.hs
+++ b/src/Plugins/Monitors/Volume.hs
@@ -14,7 +14,7 @@
module Plugins.Monitors.Volume (runVolume, volumeConfig) where
-import Control.Monad ( liftM )
+import Control.Monad ( liftM, mplus )
import Data.Maybe
import Plugins.Monitors.Common
import Sound.ALSA.Mixer
@@ -108,9 +108,9 @@ runVolume :: String -> String -> [String] -> Monitor String
runVolume mixerName controlName argv = do
opts <- io $ parseOpts argv
control <- liftM fromJust $ io $ getControlByName mixerName controlName
- let volumeControl = fromJust $ maybe (playback $ volume control) Just
+ let volumeControl = fromJust $ mplus (playback $ volume control)
(common $ volume control)
- switchControl = fromJust $ maybe (playback $ switch control) Just
+ switchControl = fromJust $ mplus (playback $ switch control)
(common $ switch control)
maybeNA = maybe (return "N/A")
(lo, hi) <- io $ getRange volumeControl