diff --git a/src/modules/stellar/services/stellar.service.ts b/src/modules/stellar/services/stellar.service.ts index 850bceb0..74235d80 100644 --- a/src/modules/stellar/services/stellar.service.ts +++ b/src/modules/stellar/services/stellar.service.ts @@ -68,11 +68,14 @@ export class StellarService { return this.wrap(() => this.client.submitPayment(params)); } - async getTransactionInfo( - txHash: string, - network: StellarNetworkName, - ): Promise { - return this.wrap(() => this.client.getTransaction(txHash, network)); + async getTransactionInfo(txHash: string, network: StellarNetworkName): Promise { + return this.wrap(async () => { + const info = await this.client.getTransaction(txHash, network); + if (!info) { + throw new DomainException(ErrorCode.NOT_FOUND, `Transaction '${txHash}' not found`); + } + return info; + }); } async simulateTransaction(transactionXdr: string): Promise {