({
contract,
})
| 65 | const name = 'Etherscan' |
| 66 | |
| 67 | const getCacheKey: Parameters<typeof fetch>[0]['getCacheKey'] = ({ |
| 68 | contract, |
| 69 | }) => { |
| 70 | if (typeof contract.address === 'string') |
| 71 | return `${camelCase(name)}:${contract.address}` |
| 72 | return `${camelCase(name)}:${JSON.stringify(contract.address)}` |
| 73 | } |
| 74 | |
| 75 | return fetch({ |
| 76 | cacheDuration, |