Skip to content

Kazimer Corp

  • Clients
  • Articles
  • Downloads
  • Contact

edit_user

WordPress user profile update deletes custom roles (fixed)

November 26, 2021December 22, 2019 by Kazimer Corp

WordPress allows you to add custom security roles and capabilities for users. Unfortunately, the code that updates a user profile deletes any custom roles assigned to a user when saving a user profile. This article shows a work-around that restores custom roles after a user profile update deletes them.

Categories Programming, Tutorials, WordPress Tags bug fix, custom roles, edit_user, edit_user_profile, how to, roles and capabilities, show_user_profile, solution, User Profile editor, user_profile_update_errors, WordPress, wp_update_user, WP_User

Recent Articles

  • Fix ModSecurity false positives on __cf_bm CloudFlare cookie
  • CloudFlare Rate Limiting Rules for WordPress
  • jQuery.submit() form data not submitted.
  • My images are messed up in WordPress 5.9
  • Fix Elementor’s “Exit to Dashboard” button

Categories

  • Hardware
  • Joomla!
  • Linux
  • Programming
  • Security
  • Tutorials
  • Windows
  • WordPress
  • Contact Info
  • Privacy Policy
  • DMCA Policy
©2002 - 2023 • Kazimer Corp.