Skip to content
Snippets Groups Projects
tc-core-update-minor.php 726 B
Newer Older
  • Learn to ignore specific revisions
  • Kevin Cristiano's avatar
    Kevin Cristiano committed
    <?php
    /**
    
    Kevin Cristiano's avatar
    Kevin Cristiano committed
     * Plugin Name:     Set Auto Updates to minor releases only
    
    Kevin Cristiano's avatar
    Kevin Cristiano committed
     * Plugin URI:      https://tadpole.cc
    
    Kevin Cristiano's avatar
    Kevin Cristiano committed
     * GitLab Plugin URI: plugins/tc-core-update-minorr
     * GitLab Plugin URI: https://develop.tadpole.cc/plugins/tc-core-update-minor.git
    
    Kevin Cristiano's avatar
    Kevin Cristiano committed
     * Description:     Allow automatic updates for security releases only 
     * Author:          Kevin Cristiano
     * Author URI:      https://tadpole.cc
     * Text Domain:     tc-core-update-minor
     * Domain Path:     /languages
    
    Kevin Cristiano's avatar
    Kevin Cristiano committed
     * Version:         1.0
    
    Kevin Cristiano's avatar
    Kevin Cristiano committed
     *
     * @package         Tc_Core_Update_Minor
     */
    
    
    Kevin Cristiano's avatar
    Kevin Cristiano committed
    add_filter( 'allow_major_auto_core_updates', '__return_false' );
    
    add_action(
        'admin_notices',
        function() {
            remove_action( 'admin_notices', 'update_nag', 3 );
        },
        2
    );