Remove either error id pattern in Samples

This commit is contained in:
Seungheon Oh 2022-06-17 14:29:00 -05:00
parent 071a6ca7cc
commit a8699bf992
6 changed files with 31 additions and 30 deletions

View file

@ -67,8 +67,9 @@ genMultiSigProp prop = do
MeetsMinSigs -> chooseInt (minSig, length pkhs)
DoesNotMeetMinSigs -> chooseInt (0, minSig - 1)
let builder = mconcat $ signedWith <$> take n pkhs <> othersigners
txinfo = either error id $ buildTxInfo builder
let builder :: BaseBuilder
builder = mconcat $ signedWith <$> take n pkhs <> othersigners
txinfo = buildTxInfoUnsafe builder
pure (ms, ScriptContext txinfo (Spending (TxOutRef "" 0)))
-- | Classify model into propositions.