Skip to content

Commit a76c995

Browse files
authored
Merge pull request #92 from jetstack/fix_empty_user_matching_rules
Fix noop team resource updates for empty user matching rules
2 parents 7900973 + 1d6d109 commit a76c995

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

internal/provider/team_resource.go

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,9 @@ func (r *teamResource) Read(ctx context.Context, req resource.ReadRequest, resp
211211
})
212212
}
213213

214-
state.UserMatchingRules = umr
214+
if len(umr) > 0 {
215+
state.UserMatchingRules = umr
216+
}
215217

216218
diags = resp.State.Set(ctx, state)
217219
resp.Diagnostics.Append(diags...)

0 commit comments

Comments
 (0)