isBinary :: FilePath -> IO (Maybe BS.ByteString )
isBinary fileName = do
    content <- BS.readFile fileName
    if BS.length content < 84
        then return Nothing
        else
            let facetsCount = runGet getWord32le $ BS.take 4 (BS.drop 80 content)
              in if BS.length content ==  84 + fromIntegral facetsCount * 50
                then return (Just content)
                else return Nothing
isBinary :: FilePath -> IO (Maybe BS.ByteString )
isBinary fileName = do
    content <- BS.readFile fileName
    if BS.length content < 84
        then return Nothing
        else
            let facetsCount = runGet getWord32le $ BS.take 4 (BS.drop 80 content)
              in if BS.length content ==  84 + fromIntegral facetsCount * 50
                then return (Just content)
                else return Nothing
isBinary fileName = do
    content <- BS.readFile fileName
    if BS.length content < 84
        then return Nothing
        else
            let facetsCount = runGet getWord32le $ BS.take 4 (BS.drop 80 content)
              in if BS.length content ==  84 + fromIntegral facetsCount * 50
                then return (Just content)
                else return Nothing