Skip to content

Commit

Permalink
Fix useSelect subscription
Browse files Browse the repository at this point in the history
  • Loading branch information
ellatrix committed Jul 3, 2020
1 parent 762c12a commit bb0ae85
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/block-editor/src/hooks/color.js
Original file line number Diff line number Diff line change
Expand Up @@ -346,8 +346,8 @@ export const withColorPaletteStyles = createHigherOrderComponent(
( BlockListBlock ) => ( props ) => {
const { name, attributes } = props;
const { backgroundColor, textColor } = attributes;
const { colors } = useSelect( ( select ) => {
return select( 'core/block-editor' ).getSettings();
const colors = useSelect( ( select ) => {
return select( 'core/block-editor' ).getSettings().colors;
}, [] );

if ( ! hasColorSupport( name ) ) {
Expand Down

0 comments on commit bb0ae85

Please sign in to comment.