Skip to content

Instantly share code, notes, and snippets.

@jeremyfelt
Created December 13, 2013 05:43
Show Gist options
  • Select an option

  • Save jeremyfelt/7940247 to your computer and use it in GitHub Desktop.

Select an option

Save jeremyfelt/7940247 to your computer and use it in GitHub Desktop.
<?php
add_filter( 'pre_set_site_transient_update_core', 'jf_force_autoupdate_response', 10, 1 );
function jf_force_autoupdate_response( $value ) {
if ( isset( $value->updates[0]->response ) && 'upgrade' === $value->updates[0]->response ) {
$value->updates[0]->response = 'autoupdate';
}
return $value;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment