mirror of
https://gitee.com/milvus-io/milvus.git
synced 2026-01-07 19:31:51 +08:00
Fix nil pointer access (#23919)
Signed-off-by: Enwei Jiao <enwei.jiao@zilliz.com>
This commit is contained in:
parent
e13d900398
commit
240c5625cd
@ -64,7 +64,7 @@ func (b *BalanceChecker) replicasToBalance() []int64 {
|
||||
// all replicas belonging to loading collection will be skipped
|
||||
loadedCollections := lo.Filter(ids, func(cid int64, _ int) bool {
|
||||
collection := b.meta.GetCollection(cid)
|
||||
return collection != nil && b.meta.GetCollection(cid).Status == querypb.LoadStatus_Loaded
|
||||
return collection != nil && collection.Status == querypb.LoadStatus_Loaded
|
||||
})
|
||||
sort.Slice(loadedCollections, func(i, j int) bool {
|
||||
return loadedCollections[i] < loadedCollections[j]
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user