Changeset 12298
- Timestamp:
- 12/05/2022 08:52:35 AM (3 years ago)
- Location:
- sites/trunk/profiles.wordpress.org/public_html/wp-content/plugins
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/profiles.wordpress.org/public_html/wp-content/plugins/wporg-profiles-activity-handler/wporg-profiles-activity-handler.php
r12016 r12298 39 39 add_filter( 'bp_activity_meta_tables', array( $this, 'change_meta_table_names' ) ); 40 40 add_filter( 'bp_active_components', array( $this, 'activate_activity_component' ) ); 41 add_action( 'bp_setup_cache_groups', array( $this, 'bp_setup_cache_groups' ), 11 ); 41 42 add_action( 'plugins_loaded', array( $this, 'plugins_loaded' ) ); 42 43 … … 45 46 add_filter( 'bp_activity_do_mentions', '__return_false' ); 46 47 add_filter( 'bp_activity_use_akismet', '__return_false' ); 48 47 49 } 48 50 … … 106 108 107 109 return $tables; 110 } 111 112 /** 113 * Make the cache-group localised to the profile site. 114 * 115 * See https://core.trac.wordpress.org/ticket/54303 for remove_global_group. 116 */ 117 public function bp_setup_cache_groups() { 118 global $wp_object_cache; 119 120 if ( ! is_object( $wp_object_cache ) || 'WPORG_Object_Cache' !== get_class( $wp_object_cache ) ) { 121 return; 122 } 123 124 $wp_object_cache->global_groups = array_diff( 125 $wp_object_cache->global_groups, 126 [ 127 'bp_activity', 128 'bp_activity_comments', 129 'activity_meta' 130 ] 131 ); 108 132 } 109 133 -
sites/trunk/profiles.wordpress.org/public_html/wp-content/plugins/wporg-profiles-association-handler/wporg-profiles-association-handler.php
r12127 r12298 22 22 add_filter( 'bp_groups_meta_tables', array( $this, 'change_meta_table_names' ) ); 23 23 add_filter( 'bp_active_components', array( $this, 'activate_groups_component' ) ); 24 add_action( 'bp_setup_cache_groups', array( $this, 'bp_setup_cache_groups' ), 11 ); 25 24 26 add_action( 'plugins_loaded', array( $this, 'plugins_loaded' ) ); 25 27 } … … 70 72 return $tables; 71 73 } 74 75 /** 76 * Make the cache-group localised to the profile site. 77 * 78 * See https://core.trac.wordpress.org/ticket/54303 for remove_global_group. 79 */ 80 public function bp_setup_cache_groups() { 81 global $wp_object_cache; 82 83 if ( ! is_object( $wp_object_cache ) || 'WPORG_Object_Cache' !== get_class( $wp_object_cache ) ) { 84 return; 85 } 86 87 $wp_object_cache->global_groups = array_diff( 88 $wp_object_cache->global_groups, 89 [ 90 'bp_groups', 91 'bp_group_admins', 92 'bp_group_invite_count', 93 'group_meta', 94 'bp_groups_memberships', 95 'bp_groups_memberships_for_user', 96 'bp_group_mods', 97 'bp_groups_invitations_as_memberships', 98 'bp_groups_group_type' 99 ] 100 ); 101 } 102 72 103 73 104 /**
Note: See TracChangeset
for help on using the changeset viewer.