Permalink
Browse files

blob: cleanup, remove build warnings

  • Loading branch information...
1 parent 101c18a commit 7b35b60ce13b4717ab937509343d000b4d0a6d86 @kfish committed May 11, 2011
Showing with 2 additions and 6 deletions.
  1. +2 −6 Git/Blob.hs
View
@@ -9,15 +9,13 @@ module Git.Blob (
import Codec.Compression.Zlib
import Control.Applicative ((<$>))
import Control.Monad
-import qualified Data.ByteString as BS
import qualified Data.ByteString.Lazy as L
import qualified Data.ByteString.Lazy.Char8 as C
import Data.Maybe (listToMaybe)
-- show-prefix, show-root use these
import System.FilePath
import System.Posix.Files
-import System.IO
import Git.Commit
import Git.Pack
@@ -33,12 +31,10 @@ readBlob blob = do
path <- gitPath ("objects" </> bH </> bT)
exists <- fileExist path
if exists
- then do
- Just . decompress <$> C.readFile path
+ then Just . decompress <$> C.readFile path
else do
let sha = readDigestBS blob
- m'po <- findInPackIdxs sha
- return $ fmap (packObjectPretty sha) m'po
+ fmap (packObjectPretty sha) <$> findInPackIdxs sha
prettyBlob :: String -> C.ByteString -> C.ByteString
prettyBlob blob bs

0 comments on commit 7b35b60

Please sign in to comment.