diff options
author | Joey Hess <joey@kitenet.net> | 2012-03-16 12:28:17 -0400 |
---|---|---|
committer | Joey Hess <joey@kitenet.net> | 2012-03-16 12:28:17 -0400 |
commit | 771052a85e3a000911e8a438012e61b3caf9c1a8 (patch) | |
tree | 068b19c71758dca9ec76a1d07c8c291806419765 /Utility/Url.hs | |
parent | b06336fa3a146e9a0ef1a1307b1fc219570795c6 (diff) |
optimize monadic ||
(||) used applicative style runs both conditions rather than short
circuiting. Add an orM that properly short-circuits.
Diffstat (limited to 'Utility/Url.hs')
-rw-r--r-- | Utility/Url.hs | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/Utility/Url.hs b/Utility/Url.hs index 8a8d732a3..86d66d83b 100644 --- a/Utility/Url.hs +++ b/Utility/Url.hs @@ -9,7 +9,6 @@ module Utility.Url ( URLString, check, exists, - canDownload, download, get ) where @@ -44,9 +43,6 @@ exists url = where size = liftM Prelude.read . lookupHeader HdrContentLength . rspHeaders -canDownload :: IO Bool -canDownload = (||) <$> inPath "wget" <*> inPath "curl" - {- Used to download large files, such as the contents of keys. - - Uses wget or curl program for its progress bar. (Wget has a better one, |