From 2724b84abfacee68184524197040420e34a53e7e Mon Sep 17 00:00:00 2001 From: Blaine Heffron Date: Tue, 11 Jun 2024 15:35:12 -0400 Subject: [PATCH] docstring fixes --- src/contract/assembled_transaction.ts | 14 ++++++-------- src/contract/sent_transaction.ts | 15 +++++++++++---- 2 files changed, 17 insertions(+), 12 deletions(-) diff --git a/src/contract/assembled_transaction.ts b/src/contract/assembled_transaction.ts index 557a722ad..20f5a914f 100644 --- a/src/contract/assembled_transaction.ts +++ b/src/contract/assembled_transaction.ts @@ -509,9 +509,8 @@ export class AssembledTransaction { } /** - * Sign the transaction with the `wallet`, included previously. If you did - * not previously include one, you need to include one now that at least - * includes the `signTransaction` method. + * Sign the transaction with the signTransaction function included previously. + * If you did not previously include one, you need to include one now. */ sign = async ({ force = false, @@ -587,11 +586,10 @@ export class AssembledTransaction { } /** - * Sign the transaction with the `wallet`, included previously. If you did - * not previously include one, you need to include one now that at least - * includes the `signTransaction` method. After signing, this method will - * send the transaction to the network and return a `SentTransaction` that - * keeps track of all the attempts to fetch the transaction. + * Sign the transaction with the `signTransaction` function included previously. + * If you did not previously include one, you need to include one now. + * After signing, this method will send the transaction to the network and + * return a `SentTransaction` that keeps track * of all the attempts to fetch the transaction. */ signAndSend = async ({ force = false, diff --git a/src/contract/sent_transaction.ts b/src/contract/sent_transaction.ts index 366e00259..98bbb56b6 100644 --- a/src/contract/sent_transaction.ts +++ b/src/contract/sent_transaction.ts @@ -58,12 +58,19 @@ export class SentTransaction { } /** - * Initialize a `SentTransaction` from an existing `AssembledTransaction` and - * a `signed` AssembledTransaction. This will also send the transaction to the - * network. + * Initialize a `SentTransaction` from `options` and a `signed` + * AssembledTransaction. This will also send the transaction to the network. */ static init = async ( - /** {@link SentTransactionOptions} from which this SentTransaction was initialized */ + /** + * Configuration options for initializing the SentTransaction. + * + * @typedef {Object} SentTransactionOptions + * @property {number} [timeoutInSeconds] - Optional timeout duration in seconds for the transaction. + * @property {string} rpcUrl - The RPC URL of the network to which the transaction will be sent. + * @property {boolean} [allowHttp] - Optional flag to allow HTTP connections (default is false, HTTPS is preferred). + * @property {(xdr: xdr.ScVal) => U} parseResultXdr - Function to parse the XDR result returned by the network. + */ options: SentTransactionOptions, /** The signed transaction to send to the network */ signed: Tx,