rvv040 #67

Merged
pitmutt merged 4 commits from rvv040 into dev040 2024-04-24 17:00:41 +00:00
2 changed files with 6 additions and 6 deletions
Showing only changes of commit ebfac8438f - Show all commits

View File

@ -159,8 +159,8 @@ encodeExchangeAddress net tr = do
Just vhash
_ -> Nothing
-- | Decode an Exchange Address into a TransparentAddress
decodeExchangeAddress:: T.Text-> Maybe TransparentAddress
-- | Decode an Exchange Address into a ExchangeAddress
decodeExchangeAddress:: T.Text-> Maybe ExchangeAddress
decodeExchangeAddress ex = do
if (T.length ex ) > 1
then do
@ -174,12 +174,12 @@ decodeExchangeAddress ex = do
let transparentReceiver = bytes rawd
if hr == tMain
then Just $
TransparentAddress MainNet $
ExchangeAddress MainNet $
TransparentReceiver P2PKH (fromRawBytes transparentReceiver)
else do
if hr == tTest
then Just $
TransparentAddress TestNet $
ExchangeAddress TestNet $
TransparentReceiver P2PKH (fromRawBytes transparentReceiver)
else Nothing
else Nothing

View File

@ -1081,8 +1081,8 @@ main = do
case exch of
Nothing -> assertFailure "Failed to encode Exchange address"
Just addr -> do
let tadr = decodeExchangeAddress addr
tadr `shouldNotBe` Nothing
let eadr = decodeExchangeAddress addr
eadr `shouldNotBe` Nothing
-- | Properties
prop_PhraseLength :: Property