Skip to content

Commit

Permalink
Merge pull request kubernetes-sigs#554 from BinacsLee/binacs-utils-pr…
Browse files Browse the repository at this point in the history
…edicates-cleanup

code cleanup: remove check on length
  • Loading branch information
(Brien Dieterle) committed Apr 26, 2021
2 parents b0b6e58 + c971d65 commit 33f7271
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions pkg/utils/predicates.go
Original file line number Diff line number Diff line change
Expand Up @@ -95,10 +95,6 @@ type taintsFilterFunc func(*v1.Taint) bool
// TolerationsTolerateTaintsWithFilter checks if given tolerations tolerates
// all the taints that apply to the filter in given taint list.
func TolerationsTolerateTaintsWithFilter(tolerations []v1.Toleration, taints []v1.Taint, applyFilter taintsFilterFunc) bool {
if len(taints) == 0 {
return true
}

for i := range taints {
if applyFilter != nil && !applyFilter(&taints[i]) {
continue
Expand Down

0 comments on commit 33f7271

Please sign in to comment.