Skip to content

Instantly share code, notes, and snippets.

@robertdall
Last active December 28, 2015 11:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save robertdall/7491488 to your computer and use it in GitHub Desktop.
Save robertdall/7491488 to your computer and use it in GitHub Desktop.
Mutes update email on beta site
<?php
/**
* @package otto-mute
* @version 0.1
*/
/*
Plugin Name: Otto Mute
Description: Mute's daily email from beta site updates
Author: Robert Dall & Otto Wood
Version: 0.1
Author URI: http://robertdall.com
*/
// Mutes Email on beta site
function update_no_email_on_success($send, $type, $core_update, $result) {
if ( $type == 'success' ) {
$send = false;
}
return $send;
}
add_filter('auto_core_update_send_email', 'update_no_email_on_success', 10, 4);
// Mutes daily debug email
add_filter('automatic_updates_send_debug_email','__return_false');
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment