Skip to content

Commit

Permalink
fix: return error in case taxonomies fails with any error (#121)
Browse files Browse the repository at this point in the history
Co-authored-by: utsav14nov <[email protected]>
  • Loading branch information
utsav14nov and utsav14nov authored Feb 7, 2024
1 parent 54ede0c commit 57cd794
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions plugins/providers/dataplex/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,11 @@ func (p *policyTagClient) GetPolicies(ctx context.Context) ([]*Policy, error) {
policyTags := make([]*Policy, 0)
for {
taxonomy, err := taxonomies.Next()
if err == iterator.Done {
break
if err != nil {
if err == iterator.Done {
break
}
return nil, err
}
tags := p.policyManager.ListPolicyTags(ctx, &pb.ListPolicyTagsRequest{
Parent: taxonomy.Name,
Expand Down

0 comments on commit 57cd794

Please sign in to comment.