mirror of
https://github.com/10h30/ultimatemember.git
synced 2026-06-05 15:09:37 +09:00
- fixed issue with noindex profile role meta value;
This commit is contained in:
@@ -1743,11 +1743,11 @@ if ( ! class_exists( 'um\core\User' ) ) {
|
||||
$role = UM()->roles()->get_priority_user_role( $user_id );
|
||||
$permissions = UM()->roles()->role_data( $role );
|
||||
|
||||
if ( isset( $permissions['profile_noindex'] ) && $permissions['profile_noindex'] === '1' ) {
|
||||
if ( isset( $permissions['profile_noindex'] ) && (bool) $permissions['profile_noindex'] ) {
|
||||
// Setting "Avoid indexing profile by search engines" in [wp-admin > Ultimate Member > User Roles > Edit Role]
|
||||
$profile_noindex = true;
|
||||
|
||||
} elseif ( ( ! isset( $permissions['profile_noindex'] ) || $permissions['profile_noindex'] === '' ) && UM()->options()->get( 'profile_noindex' ) === '1' ) {
|
||||
} elseif ( ( ! isset( $permissions['profile_noindex'] ) || $permissions['profile_noindex'] === '' ) && (bool) UM()->options()->get( 'profile_noindex' ) ) {
|
||||
// Setting "Avoid indexing profile by search engines" in [wp-admin > Ultimate Member > Settings > General > Users]
|
||||
$profile_noindex = true;
|
||||
|
||||
@@ -2174,4 +2174,4 @@ if ( ! class_exists( 'um\core\User' ) ) {
|
||||
return $replace_placeholders;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user