network-bitcoin 0.1.2 → 0.1.3
raw patch · 3 files changed
+11/−4 lines, 3 files
Files
network-bitcoin.cabal view
@@ -7,7 +7,7 @@ -- The package version. See the Haskell package versioning policy -- (http://www.haskell.org/haskellwiki/Package_versioning_policy) for -- standards guiding when and how versions should be incremented.-Version: 0.1.2+Version: 0.1.3 -- A short (one-line) description of the package. Synopsis: Interface with Bitcoin RPC@@ -28,9 +28,13 @@ . To learn more about Bitcoin, see <http://www.bitcoin.org>. .- Changes in v0.1.2+ Changes in v0.1.3 .- - support building on GHC 7.2+ - Be more lenient when accepting addresses+ .+ - Support testnet addresses+ .+ - Add FlexibleInstances for GHC 7.2 -- The license under which the package is released. License: BSD3
src/Network/Bitcoin.hs view
@@ -1,6 +1,7 @@ {-# LANGUAGE OverloadedStrings #-} {-# LANGUAGE DeriveDataTypeable #-} {-# LANGUAGE TypeSynonymInstances #-}+{-# LANGUAGE FlexibleInstances #-} -- | Communicate with a Bitcoin daemon over JSON RPC module Network.Bitcoin (
src/Network/Bitcoin/Address.hs view
@@ -26,5 +26,7 @@ then Just $ Address s else Nothing where -- TODO validate address checksum (write base58 module first)- isOK ('1':_) = (length s == 34)+ isOK ('1':_) = (length s >= 25) && (length s <= 34)+ isOK ('m':_) = (length s >= 26) && (length s <= 34)+ isOK ('n':_) = (length s >= 26) && (length s <= 34) isOK _ = False