Skip to content

Commit

Permalink
add collateral only when using plutus (#3)
Browse files Browse the repository at this point in the history
* add collateral only when using plutus

* update check isUsingPlutus

---------

Co-authored-by: tony <[email protected]>
  • Loading branch information
baymac and ljttl3q04t authored Apr 11, 2024
1 parent 7af6dc8 commit 5303d25
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/translucent/src/translucent/tx.ts
Original file line number Diff line number Diff line change
Expand Up @@ -840,8 +840,8 @@ export class Tx {
);
}
this.txBuilder.select_utxos(2);

{
const isUsingPlutus = Object.keys(this.scripts).length > 0;
if (isUsingPlutus) {
let foundUtxo = walletUTxOs.find(
(x) =>
BigInt(x.output().amount().coin().to_str()) >=
Expand Down

0 comments on commit 5303d25

Please sign in to comment.