未验证 提交 370e9d30 编写于 作者: P Philipp C. Heckel 提交者: GitHub

Update go/inst/instance_dao.go

Co-authored-by: NShlomi Noach <2607934+shlomi-noach@users.noreply.github.com>
上级 37d3cf19
......@@ -208,12 +208,12 @@ func ReadTopologyInstance(instanceKey *InstanceKey) (*Instance, error) {
// for all the instance keys and returns a slice of Instance.
func ReadTopologyInstances(instanceKeys []InstanceKey) ([]*Instance, error) {
instances := make([]*Instance, 0)
for _, replicaKey := range instanceKeys {
replica, err := ReadTopologyInstance(&replicaKey)
for _, instanceKey := range instanceKeys {
instance, err := ReadTopologyInstance(&instanceKey)
if err != nil {
return nil, err
}
instances = append(instances, replica)
instances = append(instances, instance)
}
return instances, nil
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册