Filters the number of revisions to save for the given post by its post type.
Description
Overrides both the value of WP_POST_REVISIONS and the 'wp_revisions_to_keep' filter. The dynamic portion of the hook name, $post->post_type, refers to the post type slug. Possible hook names include: <ul> <li>wp_post_revisions_to_keep</li> <li>wp_page_revisions_to_keep</li> </ul>
849*850* @since 5.8.0851*852* @param int$num Number of revisions to store.853* @param WP_Post$post Post object.854*/855$num=apply_filters("wp_{$post->post_type}_revisions_to_keep",$num,$post);856857return(int)$num;858}859860/**861* Sets up the post objectfor preview based on the post autosave.
History
Introduced in 5.8.0. Unchanged from 6.7.7 through 7.1.0.