preparing for agora-pro
This commit is contained in:
parent
a098012d59
commit
16c0c15c58
1 changed files with 16 additions and 12 deletions
|
|
@ -247,9 +247,12 @@ stakePolicy =
|
||||||
-}
|
-}
|
||||||
mkStakeValidator ::
|
mkStakeValidator ::
|
||||||
StakeRedeemerImpl ->
|
StakeRedeemerImpl ->
|
||||||
ClosedTerm (PCurrencySymbol :--> PAssetClass :--> PAssetClass :--> PValidator)
|
Term s PCurrencySymbol ->
|
||||||
mkStakeValidator impl =
|
Term s PAssetClass ->
|
||||||
plam $ \sstSymbol pstClass gstClass _datum redeemer ctx -> unTermCont $ do
|
Term s PAssetClass ->
|
||||||
|
Term s PValidator
|
||||||
|
mkStakeValidator impl sstSymbol pstClass gstClass =
|
||||||
|
plam $ \_datum redeemer ctx -> unTermCont $ do
|
||||||
ctxF <- pletFieldsC @'["txInfo", "purpose"] ctx
|
ctxF <- pletFieldsC @'["txInfo", "purpose"] ctx
|
||||||
txInfo <- pletC $ pfromData ctxF.txInfo
|
txInfo <- pletC $ pfromData ctxF.txInfo
|
||||||
txInfoF <-
|
txInfoF <-
|
||||||
|
|
@ -602,6 +605,7 @@ mkStakeValidator impl =
|
||||||
-}
|
-}
|
||||||
stakeValidator :: ClosedTerm (PCurrencySymbol :--> PAssetClass :--> PAssetClass :--> PValidator)
|
stakeValidator :: ClosedTerm (PCurrencySymbol :--> PAssetClass :--> PAssetClass :--> PValidator)
|
||||||
stakeValidator =
|
stakeValidator =
|
||||||
|
plam $
|
||||||
mkStakeValidator $
|
mkStakeValidator $
|
||||||
StakeRedeemerImpl
|
StakeRedeemerImpl
|
||||||
{ onDepositWithdraw = PStakeRedeemerHandlerTerm pdepositWithdraw
|
{ onDepositWithdraw = PStakeRedeemerHandlerTerm pdepositWithdraw
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue