WordPress user profile update deletes custom roles (fixed)
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.