func GetPoliciesMap(svc *iam.Client) map[string]types.Policy {
	result := make(map[string]types.Policy)

	params := &iam.ListPoliciesInput{}
	resp, err := svc.ListPolicies(context.TODO(), params)
	if err != nil {
		panic(err)
	}
	for _, policy := range resp.Policies {
		result[*policy.PolicyName] = policy
	}
	return result
}
// GetPoliciesMap retrieves a map of policies with the policy name as the key
// and the actual policy object as the value
GetPoliciesMap retrieves a map of policies with the policy name as the key
and the actual policy object as the value
// GetPoliciesMap retrieves a map of policies with the policy name as the key // and the actual policy object as the value
func GetPoliciesMap(svc *iam.Client) map[string]types.Policy {
	result := make(map[string]types.Policy)
	params := &iam.ListPoliciesInput{}
	resp, err := svc.ListPolicies(context.TODO(), params)
	if err != nil {
		panic(err)
	}
	for _, policy := range resp.Policies {
		result[*policy.PolicyName] = policy
	}
	return result
}
func GetPoliciesMap ( svc * iam . Client ) map [ string ] types . Policy { result := make ( map [ string ] types . Policy ) params := & iam . ListPoliciesInput { } resp , err := svc . ListPolicies ( context . TODO ( ) , params ) if err != nil { panic ( err ) } for _ , policy := range resp . Policies { result [ * policy . PolicyName ] = policy } return result }
GetPoliciesMap retrieves a map of policies with the policy name as the key
and the actual policy object as the value
GetPoliciesMap retrieves a map of policies with the policy name as the key and the actual policy object as the value