• Hi, Just started using this plugin, and it seems that when you edit a user in the backend (i.e to validate via admin) it applies the edit to a different users id, making them both the same user, essentially permanently disabling their account. Was going to have a look into the issue but couldnt find a github for this project. thanks

    https://ww.wp.xz.cn/plugins/front-end-only-users/

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

    (@rustaurius)

    Hi Stowelly,

    Is it possible that you were logged in on front-end while editing a user in the WordPress admin area?

    Thread Starter stowelly

    (@stowelly)

    Just tried reproducing it logged in and out…. and yes you are correct, editing the user while logged in does infact cause you to edit the wrong user.

    do you think this might be a simple fix?

    Thread Starter stowelly

    (@stowelly)

    just to clarify, when not logged into the front end it works correctly

    Hello guys.

    This problem is caused by the line of code on line 17 from file “Prepare_Data_For_Insertion.php” where we have this check
    if ($User_ID == "" and is_admin())“.

    When you are logged in as user in front end and in the same time (on the same browser) in admin, then for sure $User_ID is not empty as it takes the logged in user from cookie so it will skip that line and it won’t know that it’s actually the admin page.

    The fix is simple as you just need to change the lines from
    if ($User_ID == "" and is_admin())
    to
    if( is_admin() )

    and the rest should still work fine as far as I tested.

    Let me know if this helps you Rustaurius for the next release or if not, stowelly maybe you can make a quick fix yourself in the plugin until the next version with this issue fixed.

    Plugin Contributor etoilewebdesign

    (@etoilewebdesign)

    Hi StKWarrior,

    Thanks for pointing that out and suggesting the fix.
    We’ll look into implementing a fix in the next version.
    In the meantime, hope that helps stowelly.

Viewing 5 replies - 1 through 5 (of 5 total)

The topic ‘Editing users (edits wrong user)’ is closed to new replies.