Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- add_filter('jnews_frontend_submit_user_subscription', function ($value) {
- $current_user = wp_get_current_user();
- $allow = [
- 'subscriber',
- 'administrator',
- 'editor',
- 'author',
- ];
- foreach ($allow as $user) {
- if (user_can($current_user, $user)) return $value;
- }
- return false;
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement