flattenTransactionPlanResult
Retrieves all individual SingleTransactionPlanResult instances from a transaction plan result tree.
This function recursively traverses any nested structure of transaction plan results and extracts all the single results they contain. It's useful when you need to access all the individual transaction results, regardless of their organization in the result tree (parallel or sequential).
Parameters
| Parameter | Type | Description |
|---|---|---|
result | TransactionPlanResult | The transaction plan result to extract single results from |
Returns
Readonly<{
kind: "single";
message: TransactionMessage & TransactionMessageWithFeePayer<string>;
status: TransactionPlanResultStatus<TransactionPlanResultContext>;
}>[]
An array of all single transaction plan results contained in the tree