Last active
February 14, 2018 19:06
-
-
Save misfist/c87b4effa32e5a6f8248dd13c9db434b to your computer and use it in GitHub Desktop.
Function to limit the number of revisions saved
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// Alternative to defining in wp-config.php `define( 'WP_POST_REVISIONS', 3 );` | |
add_filter( 'wp_revisions_to_keep', function() { | |
return 10; | |
} ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment