Skip to content

Commit

Permalink
converted resourceType into []interface{} slice
Browse files Browse the repository at this point in the history
Signed-off-by: Hossein Rouhani <[email protected]>
  • Loading branch information
HRouhani committed Feb 23, 2024
1 parent d837d01 commit 6111971
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion providers/aws/resources/aws_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,13 +73,17 @@ func (a *mqlAwsConfig) getRecorders(conn *connection.AwsConnection) []*jobpool.J
recording = val.recording
lastStatus = val.lastStatus
}
resourceTypesInterface := make([]interface{}, len(r.RecordingGroup.ResourceTypes))
for i, resourceType := range r.RecordingGroup.ResourceTypes {
resourceTypesInterface[i] = resourceType
}
mqlRecorder, err := CreateResource(a.MqlRuntime, "aws.config.recorder",
map[string]*llx.RawData{
"name": llx.StringDataPtr(r.Name),
"roleArn": llx.StringDataPtr(r.RoleARN),
"allSupported": llx.BoolData(r.RecordingGroup.AllSupported),
"includeGlobalResourceTypes": llx.BoolData(r.RecordingGroup.IncludeGlobalResourceTypes),
"resourceTypes": llx.ArrayData(r.RecordingGroup.ResourceTypes, types.Any),
"resourceTypes": llx.ArrayData(resourceTypesInterface, types.Any),
"recording": llx.BoolData(recording),
"region": llx.StringData(regionVal),
"lastStatus": llx.StringData(lastStatus),
Expand Down

0 comments on commit 6111971

Please sign in to comment.