chore: fix some problematic function names

Signed-off-by: hishope <csqiye@126.com>
This commit is contained in:
hishope 2024-12-01 21:38:31 +08:00 committed by Martin
parent c3cdf9bca4
commit f2cd67e81f
4 changed files with 4 additions and 4 deletions

View File

@ -64,7 +64,7 @@ func (b *BaseChain) EthereumTypeGetErc20ContractBalance(addrDesc, contractDesc A
return nil, errors.New("not supported")
}
// GetContractInfo returns URI of non fungible or multi token defined by token id
// GetTokenURI returns URI of non fungible or multi token defined by token id
func (p *BaseChain) GetTokenURI(contractDesc AddressDescriptor, tokenID *big.Int) (string, error) {
return "", errors.New("not supported")
}

View File

@ -333,7 +333,7 @@ func (c *blockChainWithMetrics) EthereumTypeGetErc20ContractBalance(addrDesc, co
return c.b.EthereumTypeGetErc20ContractBalance(addrDesc, contractDesc)
}
// GetContractInfo returns URI of non fungible or multi token defined by token id
// GetTokenURI returns URI of non fungible or multi token defined by token id
func (c *blockChainWithMetrics) GetTokenURI(contractDesc bchain.AddressDescriptor, tokenID *big.Int) (v string, err error) {
defer func(s time.Time) { c.observeRPCLatency("GetTokenURI", s, err) }(time.Now())
return c.b.GetTokenURI(contractDesc, tokenID)

View File

@ -356,7 +356,7 @@ func (b *EthereumRPC) EthereumTypeGetErc20ContractBalance(addrDesc, contractDesc
return r, nil
}
// GetContractInfo returns URI of non fungible or multi token defined by token id
// GetTokenURI returns URI of non fungible or multi token defined by token id
func (b *EthereumRPC) GetTokenURI(contractDesc bchain.AddressDescriptor, tokenID *big.Int) (string, error) {
address := hexutil.Encode(contractDesc)
// CryptoKitties do not fully support ERC721 standard, do not have tokenURI method

View File

@ -124,7 +124,7 @@ type AddrContracts struct {
Contracts []AddrContract
}
// packAddrContract packs AddrContracts into a byte buffer
// packAddrContracts packs AddrContracts into a byte buffer
func packAddrContracts(acs *AddrContracts) []byte {
buf := make([]byte, 0, 128)
varBuf := make([]byte, maxPackedBigintBytes)