Changeset 11865 for trunk/src/bp-friends/bp-friends-cache.php
- Timestamp:
- 02/27/2018 01:29:33 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-friends/bp-friends-cache.php
r11123 r11865 120 120 add_action( 'friends_friendship_rejected', 'bp_friends_clear_request_cache_on_remove', 10, 2 ); 121 121 122 /** 123 * Delete individual friendships from the cache when they are changed. 124 * 125 * @since 3.0.0 126 * 127 * @param BP_Friends_Friendship $friendship Friendship object. 128 */ 129 function bp_friends_delete_cached_friendships_on_friendship_save( $friendship ) { 130 bp_core_delete_incremented_cache( $friendship->friend_user_id . ':' . $friendship->initiator_user_id, 'bp_friends' ); 131 bp_core_delete_incremented_cache( $friendship->initiator_user_id . ':' . $friendship->friend_user_id, 'bp_friends' ); 132 } 133 add_action( 'friends_friendship_after_save', 'bp_friends_delete_cached_friendships_on_friendship_save' ); 134 122 135 // List actions to clear super cached pages on, if super cache is installed. 123 136 add_action( 'friends_friendship_rejected', 'bp_core_clear_cache' );
Note: See TracChangeset
for help on using the changeset viewer.