sendSignedTransactions method

Future<List<TransactionSignature?>> sendSignedTransactions(
  1. List<String> signedTransactions, {
  2. SendTransactionConfig? config,
  3. bool? eagerError,
})

Sends the signed Transactions to the cluster for processing (default base-64 encoding).

If eagerError is true the method will return a list of non-null TransactionSignatures or a Future.error with the first error found in the response.

Implementation

Future<List<TransactionSignature?>> sendSignedTransactions(
    final List<String> signedTransactions,
    {final SendTransactionConfig? config,
    final bool? eagerError}) async {
  final List<JsonRpcResponse<String?>> responses =
      await sendSignedTransactionsRaw(
    signedTransactions,
    config: config,
    eagerError: eagerError,
  );
  return responses
      .map<TransactionSignature?>((final JsonRpcResponse response) =>
          response is JsonRpcSuccessResponse ? response.result : null)
      .toList(growable: false);
}