acf/validate_post_id хук-фильтрACF 1.0

filter for 3rd party

Использование

add_filter( 'acf/validate_post_id', 'wp_kama_acf_validate_post_id_filter' );

/**
 * Function for `acf/validate_post_id` filter-hook.
 * 
 * @param  $post_id 
 *
 * @return 
 */
function wp_kama_acf_validate_post_id_filter( $post_id ){

	// filter...
	return $post_id;
}
$post_id
-

Где вызывается хук

acf_get_valid_post_id()
acf/validate_post_id
acf/includes/api/api-helpers.php 2549
$post_id = apply_filters( 'acf/validate_post_id', $post_id, $_post_id );

Где используется хук в Advanced Custom Fields PRO

acf/includes/revisions.php 36
add_filter( 'acf/validate_post_id', array( $this, 'acf_validate_post_id' ), 10, 2 );