Skip to content

Commit

Permalink
Use map...filter
Browse files Browse the repository at this point in the history
  • Loading branch information
Mamaduka committed Jun 6, 2024
1 parent 3748d71 commit 10a0ac2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/core-data/src/queried-data/reducer.js
Original file line number Diff line number Diff line change
Expand Up @@ -233,7 +233,7 @@ const receiveQueries = compose( [
return {
itemIds: getMergedItemIds(
state?.itemIds || [],
action.items.flatMap( ( item ) => item?.[ key ] ?? [] ),
action.items.map( ( item ) => item?.[ key ] ).filter( Boolean ),
page,
perPage
),
Expand Down

0 comments on commit 10a0ac2

Please sign in to comment.