Hi,
First of all apologies me for delay in response.
Editing source codes not recommended, because you will miss it after any update.
Put the below code in your functions.php in your theme folder:
/**
* Allows to remove method for a hook by class name
*/
if( ! function_exists( 'remove_filter_from_class' ) ){
function remove_filter_from_class( $hook_name = '', $class_name ='', $method_name = '', $priority = 0 ) {
global $wp_filter;
// Take only filters on right hook name and priority
if ( !isset($wp_filter[$hook_name][$priority]) || !is_array($wp_filter[$hook_name][$priority]) )
return false;
// Loop on filters registered
foreach( (array) $wp_filter[$hook_name][$priority] as $unique_id => $filter_array ) {
// Test if filter is an array ! (always for class/method)
if ( isset($filter_array['function']) && is_array($filter_array['function']) ) {
// Test if object is a class, class and method is equal to param !
if ( is_object($filter_array['function'][0]) && get_class($filter_array['function'][0]) && get_class($filter_array['function'][0]) == $class_name && $filter_array['function'][1] == $method_name ) {
unset($wp_filter[$hook_name][$priority][$unique_id]);
}
}
}
return false;
}
}
remove_filter_from_class( 'wp_head', 'MSP_Frontend_Assets', 'meta_generator', 10 );
Regards
Averta