Skip to content

Commit

Permalink
Fix Taxonomy Example
Browse files Browse the repository at this point in the history
  • Loading branch information
widoz committed Jan 20, 2024
1 parent ae2f058 commit 5058fe3
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ document.addEventListener('DOMContentLoaded', () => {
const { Spinner } = wp.components;

const {
Set,
searchEntities,
SingularSelectControl,
ToggleControl,
Expand Down Expand Up @@ -56,12 +57,12 @@ document.addEventListener('DOMContentLoaded', () => {
);
},
entities: {
value: Immutable.OrderedSet(props.attributes.terms),
value: new Set(props.attributes.terms),
onChange: (terms) =>
props.setAttributes({ terms: terms?.toArray() }),
},
kind: {
value: Immutable.OrderedSet(props.attributes.taxonomy),
value: new Set(props.attributes.taxonomy),
options: convertEntitiesToControlOptions(
taxonomiesEntities.records(),
'name',
Expand Down

0 comments on commit 5058fe3

Please sign in to comment.