TypeChain icon indicating copy to clipboard operation
TypeChain copied to clipboard

Allow solidity "send" function

Open cryptid-chain opened this issue 3 years ago • 0 comments

LayerZero uses a function in solidity called "send" (here: https://layerzero.gitbook.io/docs/guides/master/how-to-send-a-message)

This fails to compile with TypeChain because

types/truffle-contracts/ILayerZeroEndpoint.d.ts:15:18 - error TS2430: Interface 'ILayerZeroEndpointInstance' incorrectly extends interface 'ContractInstance'.
  Types of property 'send' are incompatible.
    Type '{ (_dstChainId: string | number | BN, _destination: string, _payload: string, _refundAddress: string, _zroPaymentAddress: string, _adapterParams: string, txDetails?: TransactionDetails | undefined): Promise<...>; call(_dstChainId: string | ... 1 more ... | BN, _destination: string, _payload: string, _refundAddress: ...' is not assignable to type '(value: string | number | BN, txParams?: TransactionConfig | undefined) => PromiEvent<TransactionReceipt>'.

15 export interface ILayerZeroEndpointInstance extends Truffle.ContractInstance {
                    ~~~~~~~~~~~~~~~~~~~~~~~~~~

Is there any way around this? Or is there a way I can fix this?

cryptid-chain avatar Jul 22 '22 16:07 cryptid-chain