Merge branch 'release/2.0' of https://github.com/ultimatemember/ultimatemember into release/2.0

Conflicts:
	includes/admin/core/packages/2.0-beta1.php
This commit is contained in:
nikitozzzzzzz
2017-11-22 13:15:02 +02:00
3 changed files with 15 additions and 9 deletions
+1 -1
View File
@@ -23,7 +23,7 @@ jQuery(document).ready(function() {
jQuery(this).addClass('active');
});
jQuery(document).on('click', '.um-cover a, .um-photo a', function(e){
jQuery(document).on('click', '.um-cover a.um-cover-add, .um-photo a', function(e){
e.preventDefault();
return false;
});
+6 -2
View File
@@ -1022,6 +1022,10 @@ if ( version_compare( $wp_version, '4.9.0', '<' ) && method_exists( $wp_roles, '
}
//Content Restriction transfer
global $wp_roles;
if( method_exists($wp_roles,'_init') ){
$wp_roles->_init();
}
$roles_array = UM()->roles()->get_roles( false, array( 'administrator' ) );
$posts = get_posts( array(
@@ -1040,14 +1044,14 @@ if ( ! empty( $posts ) ) {
$access_roles = array();
if ( ! empty( $um_access_roles ) ) {
foreach ( $roles_array as $role => $role_label ) {
foreach ( $roles_array as $role => $role_label ) {
if ( in_array( substr( $role, 3 ), $um_access_roles ) )
$access_roles[ $role ] = '1';
else
$access_roles[ $role ] = '0';
}
} else {
foreach ( $roles_array as $role ) {
foreach ( $roles_array as $role => $role_label ) {
$access_roles[ $role ] = '0';
}
}
+8 -6
View File
@@ -290,14 +290,16 @@ if ( ! class_exists( 'Shortcodes' ) ) {
$post_data['template'] = $post_data['mode'];
}
$args = array_merge($post_data, $args);
if( 'directory' != $args['mode'] ) {
if ( empty( $args['use_custom_settings'] ) ) {
$args = array_merge( $args, $this->get_css_args( $args ) );
} else {
$args = array_merge( $this->get_css_args( $args ), $args );
}
$args = array_merge( $post_data, $args );
if (empty( $args['use_custom_settings'] )) {
$args = array_merge( $args, $this->get_css_args( $args ) );
} else {
$args = array_merge( $this->get_css_args( $args ), $args );
}
}
// filter for arguments
$args = apply_filters('um_shortcode_args_filter', $args);