Skip to content
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

fix(trait): condition kit type #5382

Merged
merged 1 commit into from
Apr 19, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 6 additions & 7 deletions pkg/trait/trait_condition_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,11 @@ const (
// TraitCondition is used to get all information/warning about a trait configuration.
// It should either use an IntegrationConditionType or IntegrationKitConditionType.
type TraitCondition struct {
traitID string
integrationConditionType v1.IntegrationConditionType
integrationKitConditionType v1.IntegrationKitConditionType
conditionStatus corev1.ConditionStatus
message string
reason string
traitID string
integrationConditionType v1.IntegrationConditionType
conditionStatus corev1.ConditionStatus
message string
reason string
}

func NewIntegrationCondition(traitID string, ict v1.IntegrationConditionType, cs corev1.ConditionStatus, reason, message string) *TraitCondition {
Expand Down Expand Up @@ -73,7 +72,7 @@ func (tc *TraitCondition) integrationCondition() (v1.IntegrationConditionType, c
}

func (tc *TraitCondition) integrationKitCondition() (v1.IntegrationKitConditionType, corev1.ConditionStatus, string, string) {
return v1.IntegrationKitConditionType(fmt.Sprintf("%s%s", tc.traitID, tc.integrationKitConditionType)),
return v1.IntegrationKitConditionType(fmt.Sprintf("%s%s", tc.traitID, tc.integrationConditionType)),
tc.conditionStatus,
tc.reason,
tc.message
Expand Down
Loading