Advanced Access Manager - Version 3.4.1

Version Description

  • Fixed bug with visitor access control
Download this release

Release Info

Developer vasyl_m
Plugin Icon 128x128 Advanced Access Manager
Version 3.4.1
Comparing to
See all releases

Code changes from version 3.4 to 3.4.1

Application/Backend/Manager.php CHANGED
@@ -55,7 +55,7 @@ class AAM_Backend_Manager {
55
  $this->checkExtensionList();
56
 
57
  //register backend hooks and filters
58
- if (apply_filters('aam-utility-property', 'backend-access-control', true)) {
59
  AAM_Backend_Filter::register();
60
  }
61
  }
@@ -241,7 +241,7 @@ class AAM_Backend_Manager {
241
  $u = get_user_by('id', $userId);
242
  $subject = array(
243
  'type' => 'user',
244
- 'id' => $userId,
245
  'name' => ($u->display_name ? $u->display_name : $u->user_nicename)
246
  );
247
  } else {
@@ -250,7 +250,7 @@ class AAM_Backend_Manager {
250
 
251
  $subject = array(
252
  'type' => 'role',
253
- 'id' => $role,
254
  'name' => AAM_Core_API::getRoles()->get_role($role)->name
255
  );
256
  }
55
  $this->checkExtensionList();
56
 
57
  //register backend hooks and filters
58
+ if (AAM_Core_Config::get('backend-access-control', true)) {
59
  AAM_Backend_Filter::register();
60
  }
61
  }
241
  $u = get_user_by('id', $userId);
242
  $subject = array(
243
  'type' => 'user',
244
+ 'id' => $userId,
245
  'name' => ($u->display_name ? $u->display_name : $u->user_nicename)
246
  );
247
  } else {
250
 
251
  $subject = array(
252
  'type' => 'role',
253
+ 'id' => $role,
254
  'name' => AAM_Core_API::getRoles()->get_role($role)->name
255
  );
256
  }
Application/Core/Cache.php CHANGED
@@ -79,16 +79,12 @@ class AAM_Core_Cache {
79
  public static function clear() {
80
  global $wpdb;
81
 
82
- //clear wp_options
83
- $oquery = "DELETE FROM {$wpdb->options} WHERE `option_name` LIKE %s";
84
- $wpdb->query($wpdb->prepare($oquery, 'aam_cache%' ));
85
 
86
- //clear wp_usermeta
87
- $uquery = "DELETE FROM {$wpdb->usermeta} WHERE `meta_key` LIKE %s";
88
- $wpdb->query($wpdb->prepare($uquery, 'aam_cache%' ));
89
-
90
- $mquery = "DELETE FROM {$wpdb->usermeta} WHERE `meta_key` LIKE %s";
91
- $wpdb->query($wpdb->prepare($mquery, $wpdb->prefix . 'aam_cache%' ));
92
 
93
  //clear updated flag
94
  self::$updated = false;
79
  public static function clear() {
80
  global $wpdb;
81
 
82
+ //clear visitor cache
83
+ $oquery = "DELETE FROM {$wpdb->options} WHERE `option_name` = %s";
84
+ $wpdb->query($wpdb->prepare($oquery, 'aam_visitor_cache' ));
85
 
86
+ $mquery = "DELETE FROM {$wpdb->usermeta} WHERE `meta_key` = %s";
87
+ $wpdb->query($wpdb->prepare($mquery, $wpdb->prefix . 'aam_cache' ));
 
 
 
 
88
 
89
  //clear updated flag
90
  self::$updated = false;
Application/Frontend/Manager.php CHANGED
@@ -32,7 +32,7 @@ class AAM_Frontend_Manager {
32
  * @access public
33
  */
34
  public function __construct() {
35
- if (apply_filters('aam-utility-property', 'frontend-access-control', true)) {
36
  //control WordPress frontend
37
  add_action('wp', array($this, 'wp'), 999);
38
  //filter navigation pages & taxonomies
32
  * @access public
33
  */
34
  public function __construct() {
35
+ if (AAM_Core_Config::get('frontend-access-control', true)) {
36
  //control WordPress frontend
37
  add_action('wp', array($this, 'wp'), 999);
38
  //filter navigation pages & taxonomies
aam.php CHANGED
@@ -3,7 +3,7 @@
3
  /**
4
  Plugin Name: Advanced Access Manager
5
  Description: Manage User and Role Access to WordPress Backend and Frontend.
6
- Version: 3.4
7
  Author: Vasyl Martyniuk <vasyl@vasyltech.com>
8
  Author URI: http://www.vasyltech.com
9
 
3
  /**
4
  Plugin Name: Advanced Access Manager
5
  Description: Manage User and Role Access to WordPress Backend and Frontend.
6
+ Version: 3.4.1
7
  Author: Vasyl Martyniuk <vasyl@vasyltech.com>
8
  Author URI: http://www.vasyltech.com
9
 
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: vasyltech
3
  Tags: access, role, user, capability, page, post, permission, security
4
  Requires at least: 3.8
5
  Tested up to: 4.5.3
6
- Stable tag: 3.4
7
 
8
  One of the best tools in WordPress repository to manage access to your posts,
9
  pages, categories and backend area for users, roles and visitors.
@@ -59,6 +59,9 @@ out more about the Advanced Access Manager.
59
 
60
  == Changelog ==
61
 
 
 
 
62
  = 3.4 =
63
  * Refactored backend UI implementation
64
  * Integrated Utilities extension to the core
3
  Tags: access, role, user, capability, page, post, permission, security
4
  Requires at least: 3.8
5
  Tested up to: 4.5.3
6
+ Stable tag: 3.4.1
7
 
8
  One of the best tools in WordPress repository to manage access to your posts,
9
  pages, categories and backend area for users, roles and visitors.
59
 
60
  == Changelog ==
61
 
62
+ = 3.4.1 =
63
+ * Fixed bug with visitor access control
64
+
65
  = 3.4 =
66
  * Refactored backend UI implementation
67
  * Integrated Utilities extension to the core