-
Notifications
You must be signed in to change notification settings - Fork 157
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rename labels matcher function and update test #3856
Conversation
pkg/config/piped.go
Outdated
// FindPlatformProvidersByLabel finds all PlatformProviders which match the provided labels. | ||
func (s *PipedSpec) FindPlatformProvidersByLabel(labels map[string]string, t model.ApplicationKind) []PipedPlatformProvider { | ||
// FindPlatformProvidersByLabels finds all PlatformProviders which match the provided labels. | ||
func (s *PipedSpec) FindPlatformProvidersByLabels(labels map[string]string, t model.ApplicationKind) ([]PipedPlatformProvider, bool) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Do we really need the found
return value?
I feel that only slice is enough and closer with Go conventions. 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I feel you, just want to keep this function signature as same as FindPlatformProviderByName 👍 Lets me remove it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Addressed by 3be3f14
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
What this PR does / why we need it:
This PR does:
Change the FindPlatformProvidersByLabels function signature to same as FindPlatformProviderByNameWhich issue(s) this PR fixes:
Fixes #
Does this PR introduce a user-facing change?: