Transition function throws an error. Here it is.
transition :: FreelanceContract -> State FContractDatum -> FContractRedeemer -> Maybe (TxConstraints Void Void, State FContractDatum) transition fc s r = case (stateValue s, stateData s, r) of _ -> Just (Constraints.mustBeSignedBy (freelancer fc) , State (FContractDatum 1 (Just 0)) (lovelaceValueOf 2))
Here is the wallet code for submitting the transaction
case m of Nothing -> throwError "Contract ouput not found" Just ((o, _), _) -> case tyTxOutData o of FContractDatum 0 Nothing -> do logInfo @String "Contract found. Accepting..." void $ mapError' $ runStep client Accept logInfo @String "Contract Accepted" _ -> throwError "unexpected datum"
I have boiled this code down to its simplest parts, but still, the error persists. :/