func (d Deployer) DeployToken(receiver Address, amount *big.Int) (*ERC20Token, *types.Transaction, error) {
	callOptions := &bind.CallOpts{Pending: true}
	txOptions := bind.NewKeyedTransactor(d.Wallet.PrivateKey)

	address, tx, token, err := interfaces.DeployToken(txOptions, d.Backend, receiver, amount)
	if err != nil && err.Error() == "replacement transaction underpriced" {
		txOptions.Nonce = d.GetNonce()
		address, tx, token, err = interfaces.DeployToken(txOptions, d.Backend, receiver, amount)
	} else if err != nil {
		return nil, nil, err
	}

	return &ERC20Token{
		Address:       address,
		Contract:      token,
		CallOptions:   callOptions,
		TxOptions:     txOptions,
		DefaultSender: d.Wallet,
	}, tx, nil
}
// DeployToken deploys a mock ERC20 token. The given `receiver` address receives `amount` tokens. This function
// makes a complete deployment
DeployToken deploys a mock ERC20 token. The given `receiver` address receives `amount` tokens. This function
makes a complete deployment
// DeployToken deploys a mock ERC20 token . The given ` receiver ` address receives ` amount ` tokens . This function // makes a complete deployment
func (d Deployer) DeployToken(receiver Address, amount *big.Int) (*ERC20Token, *types.Transaction, error) {
	callOptions := &bind.CallOpts{Pending: true}
	txOptions := bind.NewKeyedTransactor(d.Wallet.PrivateKey)
	address, tx, token, err := interfaces.DeployToken(txOptions, d.Backend, receiver, amount)
	if err != nil && err.Error() == "replacement transaction underpriced" {
		txOptions.Nonce = d.GetNonce()
		address, tx, token, err = interfaces.DeployToken(txOptions, d.Backend, receiver, amount)
	} else if err != nil {
		return nil, nil, err
	}
	return &ERC20Token{
		Address:       address,
		Contract:      token,
		CallOptions:   callOptions,
		TxOptions:     txOptions,
		DefaultSender: d.Wallet,
	}, tx, nil
}
func ( d Deployer ) DeployToken ( receiver Address , amount * big . Int ) ( * ERC20Token , * types . Transaction , error ) { callOptions := & bind . CallOpts { Pending : true } txOptions := bind . NewKeyedTransactor ( d . Wallet . PrivateKey ) address , tx , token , err := interfaces . DeployToken ( txOptions , d . Backend , receiver , amount ) if err != nil && err . Error ( ) == " " { txOptions . Nonce = d . GetNonce ( ) address , tx , token , err = interfaces . DeployToken ( txOptions , d . Backend , receiver , amount ) } else if err != nil { return nil , nil , err } return & ERC20Token { Address : address , Contract : token , CallOptions : callOptions , TxOptions : txOptions , DefaultSender : d . Wallet , } , tx , nil }
DeployToken deploys a mock ERC20 token.
DeployToken deploys a mock ERC20 token .