[buddypress-trac] [BuddyPress Trac] #6134: "Default" setting doesnt work for checkboxes

buddypress-trac noreply at wordpress.org
Sat Feb 21 14:27:50 UTC 2015


#6134: "Default" setting doesnt work for checkboxes
----------------------------------+---------------------
 Reporter:  sooskriszta           |       Owner:  djpaul
     Type:  defect (bug)          |      Status:  closed
 Priority:  high                  |   Milestone:  2.3
Component:  Component - XProfile  |     Version:  2.0
 Severity:  normal                |  Resolution:  fixed
 Keywords:                        |
----------------------------------+---------------------
Changes (by djpaul):

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


Comment:

 In [changeset:"9521"]:
 {{{
 #!CommitTicketReference repository="" revision="9521"
 xprofile: fix broken selection of default values for checkboxes, select
 boxes, and multi-select boxes.

 When we try to fetch a user's profile field value from the database, if it
 wasn't set, then we return an empty string.
 A few profile field types were mishandling an empty string response from
 `BP_XProfile_ProfileData::get_value_byid`, and it was being mistakenly
 interpreted as a user selected value.

 This change checks the return value from
 `BP_XProfile_ProfileData::get_value_byid`, and if it's empty, instead of
 always casting the value, sets the ongoing variable to an empty array
 instead.

 Fixes #6134
 }}}

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


More information about the buddypress-trac mailing list