Skip to content

Commit

Permalink
Add tx receipt to polling relayer
Browse files Browse the repository at this point in the history
  • Loading branch information
yorhodes committed May 4, 2024
1 parent be2407d commit b26e8aa
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions typescript/sdk/src/core/HyperlaneCore.ts
Original file line number Diff line number Diff line change
Expand Up @@ -261,13 +261,15 @@ export class HyperlaneCore extends HyperlaneApp<CoreFactories> {
const mailbox = this.getContracts(chain).mailbox;
mailbox.on<DispatchEvent>(
mailbox.filters.Dispatch(...filter),
async (_sender, _destination, _recipient, message) => {
async (sender, destination, recipient, message, event) => {
this.logger.info(
{ chain, message },
{ chain, sender, destination, recipient, message, event },
`Observed message from ${chain}, attempting to relay`,
);
const receipt = await event.getTransactionReceipt();
await this.relayMessage(
HyperlaneCore.parseDispatchedMessage(message),
receipt,
);
},
);
Expand Down

0 comments on commit b26e8aa

Please sign in to comment.