Browse Source

Fixed null-ref error when previewing colors for any theme but Skatepark (#5014)

Jason Crist 3 years ago
parent
commit
e463147f1d
1 changed files with 1 additions and 1 deletions
  1. 1 1
      blockbase/inc/customizer/wp-customize-colors-preview.js

+ 1 - 1
blockbase/inc/customizer/wp-customize-colors-preview.js

@@ -25,7 +25,7 @@ function blockBaseUpdateColorsPreview( palette ) {
 	);
 	styleElement.innerHTML = innerHTML;
 
-	if ( userColorDuotone ) {
+	if ( window.userColorDuotone ) {
 		const colors = palette.map( ( paletteItem ) => paletteItem.color );
 		//we are inverting the order when we have a darker background so that duotone looks good.
 		colors.sort( ( first, second ) => {