|
|
@ -158,11 +158,13 @@ func (ss *ShardingState) UpdateShardingState(stakeInfo *map[common.Address]*stru |
|
|
|
addr.SetBytes(addrBytes) |
|
|
|
addr.SetBytes(addrBytes) |
|
|
|
oldAddresses[addr] = true |
|
|
|
oldAddresses[addr] = true |
|
|
|
_, ok := (*stakeInfo)[addr] |
|
|
|
_, ok := (*stakeInfo)[addr] |
|
|
|
if !ok { |
|
|
|
if ok { |
|
|
|
// Remove the node if it's no longer staked
|
|
|
|
|
|
|
|
newNodeList = append(newNodeList, nodeID) |
|
|
|
newNodeList = append(newNodeList, nodeID) |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
// Remove the node if it's no longer staked
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
shard.NodeList = newNodeList |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
newAddresses := []types.NodeID{} |
|
|
|
newAddresses := []types.NodeID{} |
|
|
|