@@ -302,7 +302,7 @@ public function get_the_post_excerpt( $excerpt_length = 400 ) {
302302
303303 /** This filter is documented in wp-includes/formatting.php */
304304 $ excerpt_more = \apply_filters ( 'excerpt_more ' , ' [...] ' );
305- $ excerpt_more_len = strlen ( $ excerpt_more );
305+ $ excerpt_more_len = strlen ( $ excerpt_more );
306306
307307 // We now have a excerpt, but we need to check it's length, it may be longer than we want for two reasons:
308308 //
@@ -324,7 +324,7 @@ public function get_the_post_excerpt( $excerpt_length = 400 ) {
324324
325325 // This is a loop since we can't calculate word break the string after 'the_excpert' filter has run (we would break
326326 // all kinds of html tags), so we have to cut the excerpt down a bit at a time until we hit our target length.
327- while ( $ current_excerpt_length > $ target_excerpt_length && $ current_excerpt_max > 0 ) {
327+ while ( $ current_excerpt_length > $ target_excerpt_length && $ current_excerpt_max > 0 ) {
328328 // Trim the excerpt based on wordwrap() positioning.
329329 // Note: we're using <br> as the linebreak just in case there are any newlines existing in the excerpt from the user.
330330 // There won't be any <br> left after we've run wp_strip_all_tags() in the code above, so they're
@@ -333,7 +333,7 @@ public function get_the_post_excerpt( $excerpt_length = 400 ) {
333333
334334 // If something went wrong, or we're in a language that wordwrap() doesn't understand,
335335 // just chop it off and don't worry about breaking in the middle of a word.
336- if ( strlen ( $ excerpt ) > $ excerpt_length - $ excerpt_more_len ) {
336+ if ( strlen ( $ excerpt ) > $ excerpt_length - $ excerpt_more_len ) {
337337 $ excerpt = substr ( $ excerpt , 0 , $ current_excerpt_max );
338338 }
339339
@@ -347,7 +347,7 @@ public function get_the_post_excerpt( $excerpt_length = 400 ) {
347347 $ current_excerpt_length = strlen ( $ excerpt_filtered );
348348
349349 // Check to see if we're over the target length.
350- if ( $ current_excerpt_length > $ target_excerpt_length ) {
350+ if ( $ current_excerpt_length > $ target_excerpt_length ) {
351351 // If so, remove 20 characters from the current max and run the loop again.
352352 $ current_excerpt_max = $ current_excerpt_max - 20 ;
353353 }
0 commit comments