diff --git a/src/wp-includes/blocks/post-excerpt.php b/src/wp-includes/blocks/post-excerpt.php index 4ed4edab95078..922ca5111f7a0 100644 --- a/src/wp-includes/blocks/post-excerpt.php +++ b/src/wp-includes/blocks/post-excerpt.php @@ -83,7 +83,7 @@ function register_block_core_post_excerpt() { * the excerpt length block setting has no effect. * Returns 100 because 100 is the max length in the setting. */ -if ( is_admin() || +if ( is_admin() && ! wp_doing_ajax() || defined( 'REST_REQUEST' ) && REST_REQUEST ) { add_filter( 'excerpt_length',