Skip to content

Commit 70129f5

Browse files
authored
fix: send_transactions opts (#343)
1 parent 094d24b commit 70129f5

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/solana/rpc/api.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1035,7 +1035,7 @@ def send_transaction(
10351035
if recent_blockhash is not None:
10361036
msg = "recent_blockhash arg is not used when sending VersionedTransaction."
10371037
raise ValueError(msg)
1038-
versioned_tx_opts = types.TxOpts(preflight_commitment=self._commitment)
1038+
versioned_tx_opts = types.TxOpts(preflight_commitment=self._commitment) if opts is None else opts
10391039
return self.send_raw_transaction(bytes(txn), opts=versioned_tx_opts)
10401040
last_valid_block_height = None
10411041
if recent_blockhash is None:

src/solana/rpc/async_api.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1046,7 +1046,7 @@ async def send_transaction(
10461046
if recent_blockhash is not None:
10471047
msg = "recent_blockhash arg is not used when sending VersionedTransaction."
10481048
raise ValueError(msg)
1049-
versioned_tx_opts = types.TxOpts(preflight_commitment=self._commitment)
1049+
versioned_tx_opts = types.TxOpts(preflight_commitment=self._commitment) if opts is None else opts
10501050
return await self.send_raw_transaction(bytes(txn), opts=versioned_tx_opts)
10511051
last_valid_block_height = None
10521052
if recent_blockhash is None:

0 commit comments

Comments
 (0)