Skip to content

Commit

Permalink
revert me
Browse files Browse the repository at this point in the history
Signed-off-by: Logan Nguyen <[email protected]>
  • Loading branch information
quiet-node committed Dec 22, 2024
1 parent 50a6d00 commit fff2743
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions packages/relay/src/lib/clients/mirrorNodeClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -717,6 +717,8 @@ export class MirrorNodeClient {
}

public async getContractResult(transactionIdOrHash: string, requestDetails: RequestDetails) {
this.logger.trace(`Inside getContractResult`);
this.logger.trace(arguments);
const cacheKey = `${constants.CACHE_KEY.GET_CONTRACT_RESULT}.${transactionIdOrHash}`;
const cachedResponse = await this.cacheService.getAsync(
cacheKey,
Expand Down Expand Up @@ -770,10 +772,13 @@ export class MirrorNodeClient {
requestDetails: RequestDetails,
): Promise<any> {
const shortDelay = 500;
this.logger.trace(`Start get contract result with retry`);
const contractResult = await getContractResultFunc.call(this, ...params);
const contractObjects = Array.isArray(contractResult) ? contractResult : [contractResult];

for (const contractObject of contractObjects) {
this.logger.trace(`Looping through contractObjects`);
this.logger.trace(contractResult);
if (
contractObject &&
(contractObject.transaction_index == null ||
Expand Down

0 comments on commit fff2743

Please sign in to comment.