force topic approve edit by anonymous user
This commit is contained in:
parent
5951f34dd0
commit
e4773eb254
@ -497,6 +497,16 @@ function cbsonline_wpforo_topic_get_topics($args = [], &$items_count = 0, $count
|
|||||||
return $topics;
|
return $topics;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
// - force approve edit by anonymous user
|
||||||
|
add_filter('wpforo_edit_topic_data_filter', 'cbsonline_wpforo_edit_topic_data_filter', 100);
|
||||||
|
function cbsonline_wpforo_edit_topic_data_filter($args)
|
||||||
|
{
|
||||||
|
if (isset($args['name']) && isset($args['email'])) {
|
||||||
|
$args['status'] = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
return $args;
|
||||||
|
}
|
||||||
// - set hostname if annoymous user add topic data
|
// - set hostname if annoymous user add topic data
|
||||||
add_filter('wpforo_add_topic_data_filter', 'cbsonline_wpforo_add_topic_data_filter');
|
add_filter('wpforo_add_topic_data_filter', 'cbsonline_wpforo_add_topic_data_filter');
|
||||||
function cbsonline_wpforo_add_topic_data_filter($args)
|
function cbsonline_wpforo_add_topic_data_filter($args)
|
||||||
|
Loading…
Reference in New Issue
Block a user