Skip to content

Instantly share code, notes, and snippets.

View rafalkonofalski's full-sized avatar

Rafał Konofalski rafalkonofalski

View GitHub Profile
const tryIt = (fn, fallback = null) => {
try {
return fn();
}
catch (error) {
return fallback;
}
}
function remove_core_updates() {
global $wp_version;
return(object) array('last_checked'=> time(),'version_checked'=> $wp_version,);
}
add_filter('pre_site_transient_update_core','remove_core_updates');
add_filter('pre_site_transient_update_plugins','remove_core_updates');
add_filter('pre_site_transient_update_themes','remove_core_updates');