Im trying to run Week05's home work solution 1 on the online plutus playground enviornment but I keep getting errors in lines 79 to 84 dose anybody know how to fix this?
code pasted below along with errors
endpoints :: Contract () SignedSchema Text ()
endpoints = mint' >> endpoints
where
mint' = endpoint @"mint" >>= mint
errors
Compilation Error, Line 80, Column 13 (jump)
error:
* Couldn't match type `(->) (a0 -> Contract w0 s0 e0 b0)'
with `Contract () SignedSchema Text'
Expected type: Contract () SignedSchema Text ()
Actual type: (a0 -> Contract w0 s0 e0 b0) -> ()
* Probable cause: `(>>)' is applied to too few arguments
In the expression: mint' >> endpoints
In an equation for `endpoints':
endpoints
= mint' >> endpoints
where
mint' = endpoint @"mint" >>= mint
|
80 | endpoints = mint' >> endpoints
| ^^^^^^^^^^^^^^^^^^
Compilation Error, Line 80, Column 22 (jump)
error:
* Couldn't match type `Contract () SignedSchema Text'
with `(->) (a0 -> Contract w0 s0 e0 b0)'
Expected type: (a0 -> Contract w0 s0 e0 b0) -> ()
Actual type: Contract () SignedSchema Text ()
* In the second argument of `(>>)', namely `endpoints'
In the expression: mint' >> endpoints
In an equation for `endpoints':
endpoints
= mint' >> endpoints
where
mint' = endpoint @"mint" >>= mint
|
80 | endpoints = mint' >> endpoints
| ^^^^^^^^^
Compilation Error, Line 82, Column 13 (jump)
error:
* Couldn't match type `Promise w s e b' with `MintParams'
Expected type: (a -> Contract w s e b) -> MintParams
Actual type: (a -> Contract w s e b) -> Promise w s e b
* In the first argument of `(>>=)', namely `endpoint @"mint"'
In the expression: endpoint @"mint" >>= mint
In an equation for mint': mint' = endpoint @"mint" >>= mint
* Relevant bindings include
mint' :: (a -> Contract w s e b) -> ()
(bound at /tmp/web-ghc-work-5bba159ebc709aaf/Main.hs:82:5)
|
82 | mint' = endpoint @"mint" >>= mint
| ^^^^^^^^^^^^^^^^
Compilation Error, Line 82, Column 34 (jump)
error:
* Couldn't match type `Contract w1 SignedSchema Text'
with `(->) (a -> Contract w s e b)'
Expected type: MintParams -> (a -> Contract w s e b) -> ()
Actual type: MintParams -> Contract w1 SignedSchema Text ()
* In the second argument of `(>>=)', namely `mint'
In the expression: endpoint @"mint" >>= mint
In an equation for mint': mint' = endpoint @"mint" >>= mint
* Relevant bindings include
mint' :: (a -> Contract w s e b) -> ()
(bound at /tmp/web-ghc-work-5bba159ebc709aaf/Main.hs:82:5)
|
82 | mint' = endpoint @"mint" >>= mint
|
^^^^