Skip to content

Commit

Permalink
hlint
Browse files Browse the repository at this point in the history
  • Loading branch information
paweljakubas committed Apr 12, 2023
1 parent f8bbb15 commit b2e7ed3
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3502,10 +3502,7 @@ submitSharedTransaction ctx apiw@(ApiT wid) apitx = do
isDelegationKeyHash (KeyHash _ _) = False

hasDelegationKeyHash s =
if isTimelock s then
all isDelegationKeyHash (retrieveAllKeyHashes s)
else
False
isTimelock s && all isDelegationKeyHash (retrieveAllKeyHashes s)

joinStakePool
:: forall s n k.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1782,7 +1782,7 @@ emptySharedWalletDelegating ctx = do
[ expectResponseCode HTTP.status201
]

pure $ (getFromResponse Prelude.id rPostA, getFromResponse Prelude.id rPostB)
pure (getFromResponse Prelude.id rPostA, getFromResponse Prelude.id rPostB)

fundSharedWallet
:: forall (n :: NetworkDiscriminant) m.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -804,8 +804,6 @@ instance AccountIxForStaking (SharedState n SharedKey) where
instance ToWitnessCountCtx (SharedState n SharedKey) where
toWitnessCountCtx s =
let delegationTemplateM = delegationTemplate s
stakingKeyHashes = case delegationTemplateM of
Just delegationTemplate ->
allCosignerStakingKeys delegationTemplate
Nothing -> []
stakingKeyHashes =
maybe [] allCosignerStakingKeys delegationTemplateM
in SharedWalletCtx stakingKeyHashes
2 changes: 1 addition & 1 deletion lib/wallet/src/Cardano/Wallet/Shelley/Transaction.hs
Original file line number Diff line number Diff line change
Expand Up @@ -1226,7 +1226,7 @@ estimateKeyWitnessCount utxo txbody@(Cardano.TxBody txbodycontent) =
Cardano.StakeCredentialByScript scriptHash ->
let pair = filter (\(_,sh) -> sh == scriptHash) apiScriptHashes
in case pair of
(delScript,_):[] ->
[(delScript,_)] ->
estimateMaxWitnessRequiredPerInput delScript
_ -> error "there should be delegation script in the tx body"

Expand Down

0 comments on commit b2e7ed3

Please sign in to comment.