mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-16 08:53:46 +00:00
Update accounts/abi/bind/dep_tree.go
Co-authored-by: Martin HS <martin@swende.se>
This commit is contained in:
parent
de00bb3a29
commit
c89c24ce37
1 changed files with 1 additions and 3 deletions
|
|
@ -170,11 +170,9 @@ func (d *depTreeDeployer) linkAndDeploy(node *depTreeNode) error {
|
||||||
// a deployer bytecode for this contract.
|
// a deployer bytecode for this contract.
|
||||||
deployerCode := node.unlinkedCode
|
deployerCode := node.unlinkedCode
|
||||||
for _, child := range node.children {
|
for _, child := range node.children {
|
||||||
var linkAddr common.Address
|
linkAddr := d.deployedAddrs[child.pattern]
|
||||||
if child.overrideAddr != nil {
|
if child.overrideAddr != nil {
|
||||||
linkAddr = *child.overrideAddr
|
linkAddr = *child.overrideAddr
|
||||||
} else {
|
|
||||||
linkAddr = d.deployedAddrs[child.pattern]
|
|
||||||
}
|
}
|
||||||
deployerCode = strings.ReplaceAll(deployerCode, "__$"+child.pattern+"$__", strings.ToLower(linkAddr.String()[2:]))
|
deployerCode = strings.ReplaceAll(deployerCode, "__$"+child.pattern+"$__", strings.ToLower(linkAddr.String()[2:]))
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue