Skip to content

Commit 48ded1a

Browse files
feat(chequebook): add funding URL for mainnet users (#5284)
Co-authored-by: Copilot <[email protected]>
1 parent 57a0355 commit 48ded1a

File tree

1 file changed

+7
-0
lines changed
  • pkg/settlement/swap/chequebook

1 file changed

+7
-0
lines changed

pkg/settlement/swap/chequebook/init.go

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,9 +98,16 @@ func checkBalance(
9898
msg := fmt.Sprintf("cannot continue until there is at least min %s available on address", swarmTokenName)
9999
logger.Warning(msg, "min_amount", neededERC20, "address", overlayEthAddress)
100100
}
101+
101102
if chainId == chaincfg.Testnet.ChainID {
102103
logger.Warning("learn how to fund your node by visiting our docs at https://docs.ethswarm.org/docs/installation/fund-your-node")
103104
}
105+
106+
if chainId == chaincfg.Mainnet.ChainID {
107+
fundingURL := fmt.Sprintf("https://fund.ethswarm.org/?destination=%s&intent=initial-funding", overlayEthAddress.Hex())
108+
logger.Info(fmt.Sprintf("fund your node using the funding URL: %s", fundingURL))
109+
}
110+
104111
select {
105112
case <-time.After(balanceCheckBackoffDuration):
106113
case <-timeoutCtx.Done():

0 commit comments

Comments
 (0)