[buddypress-trac] [BuddyPress Trac] #6520: xprofile_check_is_required_field should also check for capability when in admin

buddypress-trac noreply at wordpress.org
Sat Oct 10 16:13:03 UTC 2015


#6520: xprofile_check_is_required_field should also check for capability when in
admin
-------------------------------------------------+---------------------
 Reporter:  thomaslhotta                         |       Owner:  djpaul
     Type:  defect (bug)                         |      Status:  closed
 Priority:  normal                               |   Milestone:  2.4
Component:  Component - XProfile                 |     Version:  2.3.2
 Severity:  normal                               |  Resolution:  fixed
 Keywords:  has-patch 2nd-opinion needs-testing  |
-------------------------------------------------+---------------------
Changes (by djpaul):

 * owner:   => djpaul
 * status:  new => closed
 * resolution:   => fixed


Comment:

 In [changeset:"10232"]:
 {{{
 #!CommitTicketReference repository="" revision="10232"
 xprofile: remove is_admin() logic from required field check

 The function should return the same thing for everyone, as it’s a
 property of the field only (not the field-user combo). In the relevant
 places where these functions are used in BP - namely, during form
 submission - bp_moderate users are able to bypass the requirement.

 This change breaks backwards compatibility in cases where the
 field_is_required() functions are called directly, and the plugin
 expects the function to return true for bp_moderate users. This is
 unlikely, and given that if there were, they’d run into this same bug,
 let’s fix it.

 Fixes #6520

 Props boonebgorges
 }}}

--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/6520#comment:5>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac


More information about the buddypress-trac mailing list