Skip to content

Commit

Permalink
patch: scriptDataHash recursive calc
Browse files Browse the repository at this point in the history
  • Loading branch information
micahkendall committed Sep 10, 2024
1 parent 05ac781 commit 4cddb94
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
5 changes: 5 additions & 0 deletions .changeset/blue-buttons-lay.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@blaze-cardano/tx": patch
---

patch: scriptDataHash recursive calc
6 changes: 6 additions & 0 deletions packages/blaze-tx/src/tx.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1569,6 +1569,12 @@ export class TxBuilder {
evaluationFee = await this.evaluate(draft_tx);
this.fee += evaluationFee - oldEvaluationFee;
tw.setRedeemers(this.redeemers);
{
const scriptDataHash = this.getScriptDataHash(tw);
if (scriptDataHash) {
this.body.setScriptDataHash(scriptDataHash);
}
}
draft_tx.setWitnessSet(tw);
if (evaluationFee > oldEvaluationFee) {
continue;
Expand Down

0 comments on commit 4cddb94

Please sign in to comment.