Skip to content

Commit

Permalink
simplify Inject WrapGenTxId and make it match Inject WrapHeaderHash
Browse files Browse the repository at this point in the history
  • Loading branch information
fraser-iohk committed Dec 12, 2024
1 parent 2cd30dc commit 2e5d4d8
Showing 1 changed file with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -137,8 +137,14 @@ instance Inject GenTx where
inject _ = injectNS' (Proxy @GenTx)

instance Inject WrapGenTxId where
inject _ ix w = WrapGenTxId $ HardForkGenTxId $ OneEraGenTxId $
hcollapse $ hcmap proxySingle (K . toRawTxIdHash . unwrapGenTxId) $ injectNS ix w
inject _ (idx :: Index xs x) =
case dictIndexAll (Proxy @SingleEraBlock) idx of
Dict ->
WrapGenTxId
. HardForkGenTxId
. OneEraGenTxId
. toRawTxIdHash
. unwrapGenTxId

instance Inject WrapApplyTxErr where
inject _ =
Expand Down

0 comments on commit 2e5d4d8

Please sign in to comment.