• Resolved douglas_johnson

    (@douglas_johnson)


    I am finding that if I, as an admin, upload a profile photo for a contributor, and then that contributor updates their profile, the profile photo is erased.

    I believe this is because the permission required for cupp_save_img_meta() is current_user_can(‘edit_user’), a condition which the contributor meets.

    However, each of the cupp meta fields are empty so the contributor inadvertently overwrites them to be blank.

    I stopped the problem by changing the permission in cupp_save_img_meta() to current_user_can(‘upload_files’). Since the contributor does not have this permission, the fields aren’t overwritten.

    Is there a reason the permissions for
    cupp_profile_img_fields() and cupp_save_img_meta() are different?

    https://www.ads-software.com/plugins/custom-user-profile-photo/

Viewing 1 replies (of 1 total)
  • Great find! Thank you Douglas. I’ll be sure to add this fix to the next release as a bug fix.

    Thanks for trying the plugins and providing feedback.

    Regards,
    3five

Viewing 1 replies (of 1 total)
  • The topic ‘Permissions and Overwriting’ is closed to new replies.