Skip to content

Commit

Permalink
Add IS_GUTENBERG_PLUGIN flag to LastRevision
Browse files Browse the repository at this point in the history
  • Loading branch information
mikachan committed Oct 11, 2023
1 parent 6a04d57 commit f3569a0
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,10 @@ const useRevisionData = () => {
function PostLastRevisionCheck( { children } ) {
const { lastRevisionId, revisionsCount } = useRevisionData();

if ( ! process.env.IS_GUTENBERG_PLUGIN ) {
return null;
}

if ( ! lastRevisionId || revisionsCount < 2 ) {
return null;
}
Expand Down

0 comments on commit f3569a0

Please sign in to comment.