acf/revisions/skip_legacy_metabox_handling

acf/revisions/skip_legacy_metabox_handling

Hook Type: filter

See hook in core

Displaying hooks found in version: advanced-custom-fields.6.8.2

apply_filters('acf/revisions/skip_legacy_metabox_handling') is found 2 times:

  • /includes/revisions.php line 92
    		 * @param WP_Post $post             The WP_Post object for the parent post.
    		 * @return boolean
    		 */
    		public function check_acf_fields_have_changed( $post_has_changed, $last_revision, $post ) {
    			if ( apply_filters( 'acf/revisions/skip_legacy_metabox_handling', false ) ) {
    				return $post_has_changed;
    			}
    
    			if ( acf_maybe_get_GET( 'meta-box-loader', false ) ) {
    				// We're in a legacy AJAX request, so we copy fields over to the latest revision.
    				$this->maybe_save_revision( $last_revision->ID, $post->ID );
    
  • /includes/revisions.php line 118
    		 * @param integer $post_id     The ID of the post being updated.
    		 * @return void
    		 */
    		public function maybe_save_revision( $revision_id, $post_id ) {
    			if ( apply_filters( 'acf/revisions/skip_legacy_metabox_handling', false ) ) {
    				return;
    			}
    
    			// We don't have anything to copy over yet.
    			if ( ! did_action( 'acf/save_post' ) ) {
    				delete_metadata( 'post', $post_id, '_acf_changed' );