Advertisement
wclovers

Untitled

Jan 6th, 2022
125
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.63 KB | None | 0 0
  1. function auto_update_specific_plugins ( $update, $item ) {
  2.     $plugins = array (
  3.         'wc-frontend-manager',
  4.         'wc-multivendor-marketplace',
  5.         'wc-multivendor-membership',
  6.         'wc-frontend-manager-ultimate',
  7.         'wc-frontend-manager-affiliate',
  8.         'wc-frontend-manager-analytics',
  9.         'wc-frontend-manager-delivery',
  10.         'wc-frontend-manager-groups-staffs',
  11.         'wc-frontend-manager-product-hub'
  12.     );
  13.     if ( in_array( $item->slug, $plugins ) ) {
  14.         return false;
  15.     } else {
  16.         return $update;
  17.     }
  18. }
  19. add_filter( 'auto_update_plugin', 'auto_update_specific_plugins', 10, 2 );
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement