bp_activity_has_activity_filter (has_activities美元美元的活动

过滤朋友的隐私活动

描述

参数

has_activities美元

(必需)

美元的活动

(必需)

返回

(混合)

文件:bp-activity / bp-activity-filters.php

函数bp_activity_has_activity_filter($has_activities, $activities) {if (!bb_is_active ('friends') || !Is_user_logged_in () || is_super_admin()) {return $has_activities;} if (!if ('friends' == $activity->privacy) {$remove_from_stream = false;$is_friend = friends_check_friend (bp_loggedin_user_id(), $activity->user_id);如果(!$is_friend) {$remove_from_stream = true;} if ($ activity ->activity_count) {$ activity ->activity_count = $ activity ->activity_count - 1; / /将activity的值设置为0If (isset($activities->total_activity_count)) {$activities->total_activity_count = $activities->total_activity_count - 1; / /激活> } unset( $activities->activities[ $key ] ); } } } } $activities->activities = array_values( $activities->activities ); return $has_activities; }

更新日志

更新日志
版本 描述
BuddyBoss 1.0.0 介绍了。

问题吗?

我们总是很乐意帮助您解决代码或其他问题!搜索我们的开发人员文档联络支持,或与我们联系销售团队