Skip to content

Commit

Permalink
Merge pull request #277 from jdamata/feature/fix-tests-2
Browse files Browse the repository at this point in the history
issues/248
  • Loading branch information
jdamata authored Oct 5, 2024
2 parents c07e08a + 026aa39 commit c957ee0
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions sonarqube/resource_sonarqube_project.go
Original file line number Diff line number Diff line change
Expand Up @@ -231,11 +231,13 @@ func resourceSonarqubeProjectRead(d *schema.ResourceData, m interface{}) error {
}

settings := make([]interface{}, len(componentSettings))
for i, s := range componentSettings {
key := s.(map[string]interface{})["key"].(string)
for _, apiSetting := range projectSettings {
if key == apiSetting.Key {
settings[i] = apiSetting.ToMap()
if len(componentSettings) >= 1 {
for i, s := range componentSettings {
key := s.(map[string]interface{})["key"].(string)
for _, apiSetting := range projectSettings {
if key == apiSetting.Key {
settings[i] = apiSetting.ToMap()
}
}
}
}
Expand Down

0 comments on commit c957ee0

Please sign in to comment.