From e41fd61bdeac8779fa24050cc0d44714f7c90f1d Mon Sep 17 00:00:00 2001 From: jao Date: Sat, 29 Apr 2017 02:09:24 +0200 Subject: hlint configuration --- src/Plugins/Monitors/Mpris.hs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/Plugins/Monitors/Mpris.hs') diff --git a/src/Plugins/Monitors/Mpris.hs b/src/Plugins/Monitors/Mpris.hs index 200e9f7..0228c8e 100644 --- a/src/Plugins/Monitors/Mpris.hs +++ b/src/Plugins/Monitors/Mpris.hs @@ -78,6 +78,7 @@ mprisConfig = mkMConfig " - " , "title", "tracknumber" , "composer", "genre" ] +{-# NOINLINE dbusClient #-} dbusClient :: DC.Client dbusClient = unsafePerformIO DC.connectSession @@ -106,7 +107,7 @@ unpackMetadata xs = TypeVariant -> unpack $ fromVar v TypeStructure _ -> let x = structureItems (fromVar v) in - if x == [] then [] else unpack (head x) + if null x then [] else unpack (head x) _ -> [] getMetadata :: (MprisVersion a) => a -> DC.Client -> String -> IO [(String, Variant)] @@ -141,5 +142,5 @@ makeList version md = map getStr (fieldsList version) where _ -> (show::Int64 -> String) num TypeArray TypeString -> let x = arrayItems (fromVar v) in - if x == [] then "" else fromVar (head x) + if null x then "" else fromVar (head x) _ -> "" -- cgit v1.2.3