Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
Kornel committed Jul 14, 2023
1 parent 308808a commit 8f04672
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion providers/keycloak/generator.go
Original file line number Diff line number Diff line change
Expand Up @@ -523,7 +523,7 @@ func (g *RealmGenerator) PostConvertHook() error {
}

// Sort role_ids to get reproducible results for keycloak_group_roles resources
if r.InstanceInfo.Type == "keycloak_group_roles" {
if _, exist := r.Item["role_ids"]; exist && r.InstanceInfo.Type == "keycloak_group_roles" {
sortedRoles := make([]string, len(r.Item["role_ids"].([]interface{})))
for k, v := range r.Item["role_ids"].([]interface{}) {
sortedRoles[k] = mapRoleIDs[r.Item["realm_id"].(string)+"_"+v.(string)]
Expand Down

0 comments on commit 8f04672

Please sign in to comment.