We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7c4eece commit 1363ce7Copy full SHA for 1363ce7
plugins/cognito/pkg/fetch/fetch.go
@@ -109,13 +109,11 @@ func (f *Fetcher) fetchGroups() iter.Seq2[map[string]any, error] {
109
return func(yield func(map[string]any, error) bool) {
110
for _, group := range groups {
111
groupBytes, err := json.Marshal(group)
112
- if err != nil {
113
- if !yield(nil, err) {
114
- return
115
- }
+ if err != nil && !yield(nil, err) {
+ return
116
}
117
118
- var obj map[string]interface{}
+ var obj map[string]any
119
err = json.Unmarshal(groupBytes, &obj)
120
121
if !(yield(obj, err)) {
0 commit comments