Skip to content

Commit

Permalink
added the inline suggestion
Browse files Browse the repository at this point in the history
  • Loading branch information
ashutosji committed Jul 14, 2024
1 parent decda1d commit 38093a1
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions pkg/gameserverallocations/find.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,9 @@ func findGameServerForAllocation(gsa *allocationv1.GameServerAllocation, list []
}
}
case apis.Distributed:
// Determine if Priorities are set in the Fleet spec
prioritiesSet := len(gsa.Spec.Priorities) > 0

// randomised looping - make a list of indices, and then randomise them
// as we don't want to change the order of the gameserver slice
if !runtime.FeatureEnabled(runtime.FeatureCountsAndLists) || !prioritiesSet {
if !runtime.FeatureEnabled(runtime.FeatureCountsAndLists) || len(gsa.Spec.Priorities) == 0 {
l := len(list)
indices := make([]int, l)
for i := 0; i < l; i++ {
Expand Down

0 comments on commit 38093a1

Please sign in to comment.