Skip to content

Commit

Permalink
fix php notice
Browse files Browse the repository at this point in the history
  • Loading branch information
ellatrix committed Nov 1, 2024
1 parent 809405e commit f09ccf8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/compat/wordpress-6.8/preload.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ function gutenberg_block_editor_preload_paths_6_8( $paths, $context ) {
}
}

if ( $post ) {
if ( ! empty( $post ) ) {
$route_for_post = rest_get_route_for_post( $post );
if ( $route_for_post ) {
$paths[] = add_query_arg( 'context', 'edit', $route_for_post );
Expand Down

0 comments on commit f09ccf8

Please sign in to comment.