Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
## 16-11-2026

- `WormholeGatewayAdapter`: Pass the local chain's Wormhole id as `refundChain` to `sendPayloadToEvm` instead of the destination chain's id. Refunds are now requested to `refundRecipient` on the source chain. As with any cross-chain refund, the Wormhole relayer may still fail to deliver it (e.g. if the refund amount is too small to cover delivery). The local chain must be registered with `registerChainEquivalence`, and `sendMessage` now reverts with `UnsupportedChainId` when it is not.

## 04-11-2026

- `WormholeGatewayAdapter`: `_wormholeRelayer` is now `private`. Use `relayer()` to read it.
Expand Down
6 changes: 5 additions & 1 deletion contracts/crosschain/wormhole/WormholeGatewayAdapter.sol
Original file line number Diff line number Diff line change
Expand Up @@ -194,6 +194,10 @@ contract WormholeGatewayAdapter is IERC7786GatewaySource, IWormholeReceiver, Own
// No real need to check the return value.
getRemoteGateway(recipient);

// Note: this reverts with UnsupportedChainId if the local chain is not registered. {requestRelay}
// needs it as the refund chain, so a message stored without it could never be relayed.
getWormholeChain(block.chainid);

// Store the message for future execution in {requestRelay}
_pending[sendId] = PendingMessage(true, msg.sender, msg.value, recipient, payload);

Expand Down Expand Up @@ -330,7 +334,7 @@ contract WormholeGatewayAdapter is IERC7786GatewaySource, IWormholeReceiver, Own
abi.encode(id, InteroperableAddress.formatEvmV1(block.chainid, sender), recipient, payload),
recipientValue,
gasLimit,
targetChain,
getWormholeChain(block.chainid),
refundRecipient
);
}
Expand Down