- fixed bbPress restrict content message on forums;

- fixed issues with permalinks (issue #375);
- fixed replacing placeholders in [show_content_for_role] shortcode;
This commit is contained in:
nikitozzzzzzz
2018-02-18 13:27:46 +02:00
parent 440aa59b28
commit cbf06f5835
14 changed files with 170 additions and 269 deletions
+3 -3
View File
@@ -665,20 +665,20 @@ if ( ! class_exists( 'Shortcodes' ) ) {
$current_user_roles = um_user( 'roles' );
if ( ! empty( $a['not'] ) && ! empty( $a['roles'] ) ) {
return do_shortcode( $content );
return do_shortcode( $this->convert_locker_tags( $content ) );
}
if ( ! empty( $a['not'] ) ) {
$not_in_roles = explode( ",", $a['not'] );
if ( is_array( $not_in_roles ) && count( array_intersect( $current_user_roles, $not_in_roles ) ) <= 0 ) {
return do_shortcode( $content );
return do_shortcode( $this->convert_locker_tags( $content ) );
}
} else {
$roles = explode( ",", $a['roles'] );
if ( is_array( $roles ) && count( array_intersect( $current_user_roles, $roles ) ) > 0 ) {
return do_shortcode( $content );
return do_shortcode( $this->convert_locker_tags( $content ) );
}
}