return $check;
} delete_post_meta( $post_id, '_wp_trash_meta_status'
);
delete_post_meta( $post_id, '_wp_trash_meta_time'
);
$meta =
wp_get_attachment_metadata( $post_id );
$backup_sizes =
get_post_meta( $post->ID, '_wp_attachment_backup_sizes', true
);
$file =
get_attached_file( $post_id );
if ( is_multisite() &&
is_string( $file ) && !
empty( $file ) ) { clean_dirsize_cache( $file );
} /**
* Fires before an attachment is deleted, at the start of wp_delete_attachment().
*
* @since 2.0.0
* @since 5.5.0 Added the `$post` parameter.
*
* @param int $post_id Attachment ID.
* @param WP_Post $post Post object.
*/