Skip to content

Commit c883ca4

Browse files
committed
Add DijkstraEra to transaction creation
1 parent f62733d commit c883ca4

File tree

1 file changed

+4
-3
lines changed
  • cardano-wasm/src-lib/Cardano/Wasm/Api

1 file changed

+4
-3
lines changed

cardano-wasm/src-lib/Cardano/Wasm/Api/Tx.hs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ import Cardano.Api.Plutus qualified as Shelley
3434
import Cardano.Api.Tx qualified as TxBody
3535

3636
import Cardano.Ledger.Api qualified as Ledger
37-
import Cardano.Wasm.ExceptionHandling (justOrError, rightOrError, throwError, toMonadFail)
37+
import Cardano.Wasm.ExceptionHandling (justOrError, rightOrError, toMonadFail)
3838

3939
import Control.Monad.Catch (MonadThrow)
4040
import Data.Aeson (ToJSON (toJSON), (.=))
@@ -84,8 +84,9 @@ newTxImpl :: UnsignedTxObject
8484
newTxImpl = newConwayTxImpl
8585

8686
-- | Create a new unsigned transaction object for making a transaction in the current experimental era.
87-
newExperimentalEraTxImpl :: (HasCallStack, MonadThrow m) => m UnsignedTxObject
88-
newExperimentalEraTxImpl = throwError "newExperimentalEraTxImpl: No experimental era available"
87+
newExperimentalEraTxImpl :: MonadThrow m => m UnsignedTxObject
88+
newExperimentalEraTxImpl =
89+
return $ UnsignedTxObject Exp.DijkstraEra (Exp.UnsignedTx (Ledger.mkBasicTx Ledger.mkBasicTxBody))
8990

9091
-- | Create a new unsigned transaction object for making a Conway era transaction.
9192
newConwayTxImpl :: UnsignedTxObject

0 commit comments

Comments
 (0)