[buddypress-trac] [BuddyPress Trac] #8042: visibility options for Name field appear on registration page
buddypress-trac
noreply at wordpress.org
Tue Jan 29 08:28:44 UTC 2019
#8042: visibility options for Name field appear on registration page
--------------------------+------------------------------
Reporter: msteimann | Owner: (none)
Type: defect (bug) | Status: new
Priority: high | Milestone: Awaiting Review
Component: Registration | Version: 4.1.0
Severity: normal | Resolution:
Keywords: needs-patch |
--------------------------+------------------------------
Comment (by Venutius):
I've found that this is happening because the function
`get_allow_custom_visibility` in `buddypress/xprofile/classes/class-bp-
profile-field` is defaulting to `allow` for all profile fields where the
visibility has not been specifically disabled. this is appropriate for all
profile fields except `Name` where it should be disabled even if it is not
set. my proposed fix is to change line 833 as follows:
`if ( 'disabled' === $allow_custom_visibility || 1 === $this->id ) {`
This adds an extra check to ensure the `Name` field returns as disabled,
thus fixing the issue with the registration form.
--
Ticket URL: <https://buddypress.trac.wordpress.org/ticket/8042#comment:2>
BuddyPress Trac <http://buddypress.org/>
BuddyPress Trac
More information about the buddypress-trac
mailing list