Skip to content

Commit

Permalink
chore: apply changes
Browse files Browse the repository at this point in the history
  • Loading branch information
Lyrisbee committed Jan 5, 2024
1 parent 5e0591c commit 588fbc5
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions src/triggers/class-acf-data.php
Original file line number Diff line number Diff line change
Expand Up @@ -67,17 +67,11 @@ public function run(): array {
$posts = array_filter(
$posts,
function ( $post ) {
$length = strlen( $post->post_excerpt );

if ( $length < 3 || $length > 32 ) {
return false;
}

if ( empty( $post->post_title ) || empty( $post->post_excerpt ) ) {
return false;
}

if ( preg_match( '/^[a-z_][a-z0-9_]*$/', $post->post_excerpt ) === 0 ) {
if ( preg_match( '/^[a-z_][a-z0-9_]{2,31}$/', $post->post_excerpt ) === 0 ) {
return false;
}

Expand Down

0 comments on commit 588fbc5

Please sign in to comment.