Skip to content
This repository has been archived by the owner on Mar 16, 2024. It is now read-only.

Commit

Permalink
fix: nil map assignment in features config (#2204)
Browse files Browse the repository at this point in the history
  • Loading branch information
iwilltry42 committed Oct 3, 2023
1 parent 84a3c3b commit 7a139ed
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions pkg/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -384,8 +384,12 @@ func merge(oldConfig, newConfig *apiv1.Config) *apiv1.Config {
mergedConfig.CertManagerIssuer = newConfig.CertManagerIssuer
}
if newConfig.Features != nil {
for k, v := range newConfig.Features {
mergedConfig.Features[k] = v
if mergedConfig.Features == nil {
mergedConfig.Features = newConfig.Features
} else {
for k, v := range newConfig.Features {
mergedConfig.Features[k] = v
}
}
}

Expand Down

0 comments on commit 7a139ed

Please sign in to comment.