User Role Editor Pro version 4.51 was published at May 22nd, 2019. New feature for bulk grant/revoke single role from a list of pre-selected users was added. The list of bugs were fixed.
Core version: 4.51
- New: Posts edit access add-on:
– Custom filter ‘ure_edit_posts_access_add_orders_by_customer’ was added. It returns FALSE by default. If switch it to TRUE and turn ON “Own data only” option for role or user, add-on will make available for current user WooCommerce orders for which he is a customer. It may be useful for scenario, when order customer is allowed to edit his own orders. It will prevent current user from seeing orders from other customers.
– Custom filter ‘ure_edit_access_posts_list’ was added. It allows programmatically set/change the list of posts ID which will be used to allow/prohibit editing for current user.
- Fix: Content view restrictions add-on:
– PHP notice was fixed: Undefined index: ure_prohibit_allow_flag in /wp-content/plugins/user-role-editor-pro/pro/includes/classes/content-view-restrictions-posts-list.php on lines 398, 406.
– If restriction is not set for a post or page, use default values from URE settings or hard-coded value if other is not available.
- Core version was updated to 4.51:
- New: Bulk actions were added to the Users page: “Add Role”, “Revoke Role”. Select role from the related drop-down menu and add/revoke it to/from the list of pre-selected users.
- Update: Bulk grant roles feature (“Grant roles” button at the “Users” page) and Bulk grant role to users without role (“Without role” button at the “Users” page) are protected by ‘promote_users’ capability instead of ‘edit_users’, exactly the same way as WordPress itself does for its “Change role to”.
- Update: ‘load-users.php’ action is used instead of ‘admin_init’ to load support code for “Without role” and “Grant roles” button at the “Users” page.
- Update: URE ignores now a capability without ID in case it was added to the database somehow (other plugin bug, etc.). Such incorrect empty capability is removed from the capabilities list as a result after any role update.