• Resolved escapetraffic

    (@escapetraffic)


    I updated the extension yesterday and since then, I cannot switch users to certain roles.

    In the exemple shown, I have an Admin account. I switch a user from Role ‘Client’ to Role ‘Approuved Client’ but uppon saving changes here is what happens:

    The Role is automatically set to ‘Subscriber’ AND ‘-No role for this site-‘.
    A new section also appears (never seen this before) named Additionnal Permissions. It lists all Roles I have tried to assign the user.

    Expected results (as it used to work before update):
    The users Role should now be ‘Approuved Client’ only.
    There should not be ‘Additionnal Permissions’ which I then cannot remove.

    The page I need help with: [log in to see the link]

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author Steve Burge

    (@stevejburge)

    Hi @escapetraffic

    Thanks for using PublishPress Capabilities.

    Sorry, we’ve had no more reports of this and can’t recreate this in our testing.

    Can you do more debugging:
    – Check your site’s error logs
    – Try disabling other plugins
    – Can you see the issue on a second site?

    Please let us know if you can narrow this down.

    Thread Starter escapetraffic

    (@escapetraffic)

    Hello,
    The site is in production, I cannot disable stuff and there are no logs for the moment.

    We have an older development version I will update to see if the problem reproduces, but in the meantime, here are some additionnal info:

    1- We downgraded Publishpress Capabilities from 2.3.4 to 2.3.1 and it automatically fixed the main issue: we can now save any User Role and the role is kept.

    2- Looking at the section shown in the screenshot at the bottom of user profiles ‘Additionnal Permission’. Those are not Custom Fields and were never seen before the update. in the HTML of this section there is a table row with class ‘user-capabilities-wrap’ which could relate it to your plugin.

    3- Within functions.php there is some code used that is in relations with permissions and capabilities:
    – some add_role()
    – editable_roles filter used to alter ‘read’ and ‘edit_posts’ capabilities
    That is about it.

    Is there a way to figure what changed between v2.3.1 and 2.3.4 that is stopping us to save a user’s role change using the user-edit wp admin interface?

    Plugin Author Steve Burge

    (@stevejburge)

    Hi @escapetraffic

    Sorry, you have a lot going on with this site. It’s beyond the level of support we can offer for free here on www.remarpro.com, particularly if you can’t try disabling plugins or doing that kind of detailed debugging.

    I would encourage you to update to the latest version of Capabilities, and to always have a test site for working on this sort of issue.

    If you find a bug that can be replicated, especially on a second site, please let us know.

    Thread Starter escapetraffic

    (@escapetraffic)

    Hello again,
    I have setup a test site and have found the issue being caused by compatibility due to a change happening in version 2.3.4

    Some roles were created using a different tool than PublishPress and have had spaces saved in the slug of the roles. This used to work but the roles are invalidated as of version 2.3.4

    Plugin Author Steve Burge

    (@stevejburge)

    Hi @escapetraffic

    I really don’t recommend using spaces in any WordPress slugs, and that includes user roles. Best practice would definitely be to use spaces or hyphens.

    I’ll see what we can do:
    https://github.com/publishpress/PublishPress-Capabilities/issues/307

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Switching user Role does not save the role.’ is closed to new replies.