Skip to content

Commit e1aea0b

Browse files
authored
Merge pull request #189 from k8s-proxmox/fix/empty-node-score-err
fix nil map
2 parents aa291cf + 2bc597e commit e1aea0b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cloud/scheduler/scheduler.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -342,7 +342,7 @@ func (s *Scheduler) RunFilterPlugins(ctx context.Context, state *framework.Cycle
342342
func (s *Scheduler) RunScorePlugins(ctx context.Context, state *framework.CycleState, config api.VirtualMachineCreateOptions, nodes []*api.Node) (framework.NodeScoreList, *framework.Status) {
343343
s.logger.Info("scoring proxmox node")
344344
status := framework.NewStatus()
345-
var scoresMap map[string](map[int]framework.NodeScore)
345+
scoresMap := make(map[string](map[int]framework.NodeScore))
346346
nodeInfos, err := framework.GetNodeInfoList(ctx, s.client)
347347
if err != nil {
348348
status.SetCode(1)

0 commit comments

Comments
 (0)