Skip to content

Commit

Permalink
Explicitly check for galleryBlockV2Enabled being false and default to…
Browse files Browse the repository at this point in the history
… true in other instances
  • Loading branch information
Glen Davies committed Nov 21, 2021
1 parent 8a0d02d commit dd416ed
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/block-library/src/gallery/shared.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,5 +23,5 @@ export const pickRelevantMediaFiles = ( image, sizeSlug = 'large' ) => {
};

export function isGalleryV2Enabled() {
return window.wp.galleryBlockV2Enabled;
return window.wp?.galleryBlockV2Enabled === false ? false : true;
}

0 comments on commit dd416ed

Please sign in to comment.