From 05c444079632946807e5311e24b06e13c4205515 Mon Sep 17 00:00:00 2001 From: Sam Truzjan Date: Wed, 20 Nov 2013 22:02:31 +0400 Subject: Minor changes --- src/Data/Torrent.hs | 4 ++++ src/Data/Torrent/Progress.hs | 3 +-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/Data/Torrent.hs b/src/Data/Torrent.hs index 59c4af8c..dddd1832 100644 --- a/src/Data/Torrent.hs +++ b/src/Data/Torrent.hs @@ -159,6 +159,9 @@ ppPrivacy :: Bool -> Doc ppPrivacy privacy = "Privacy: " <> if privacy then "private" else "public" +ppAdditionalInfo :: InfoDict -> Doc +ppAdditionalInfo layout = PP.empty + -- | Format info dictionary in human-readable form. ppInfoDict :: InfoDict -> Doc ppInfoDict InfoDict {..} = @@ -336,5 +339,6 @@ fromFile filepath = do Right !t -> return t Left msg -> throwIO $ userError $ msg ++ " while reading torrent file" +-- | Encode and write a .torrent file. toFile :: FilePath -> Torrent -> IO () toFile filepath = BL.writeFile filepath . encode diff --git a/src/Data/Torrent/Progress.hs b/src/Data/Torrent/Progress.hs index c1515cf0..9abf0380 100644 --- a/src/Data/Torrent/Progress.hs +++ b/src/Data/Torrent/Progress.hs @@ -1,7 +1,7 @@ {-# LANGUAGE TemplateHaskell #-} {-# LANGUAGE ViewPatterns #-} module Data.Torrent.Progress - ( -- * Peer progress + ( -- * Progress Progress (..) , left , uploaded @@ -13,7 +13,6 @@ module Data.Torrent.Progress , enqueuedProgress , uploadedProgress , dequeuedProgress - ) where import Control.Applicative -- cgit v1.2.3