diff --git a/packages/edit-site/src/components/sidebar-edit-mode/template-panel/hooks.js b/packages/edit-site/src/components/sidebar-edit-mode/template-panel/hooks.js index 199242bdc34b2..87f99e8991e45 100644 --- a/packages/edit-site/src/components/sidebar-edit-mode/template-panel/hooks.js +++ b/packages/edit-site/src/components/sidebar-edit-mode/template-panel/hooks.js @@ -51,9 +51,10 @@ function preparePatterns( patterns, template, currentThemeStylesheet ) { return patterns .filter( - filterOutExcludedPatternSources && - filterOutDuplicatesByName && - filterCompatiblePatterns + ( pattern, index, items ) => + filterOutExcludedPatternSources( pattern ) && + filterOutDuplicatesByName( pattern, index, items ) && + filterCompatiblePatterns( pattern ) ) .map( ( pattern ) => ( { ...pattern,