[buddypress-trac] [BuddyPress Trac] #8093: Field Visibility Not Honored in PHP 7.1 & above

buddypress-trac noreply at wordpress.org
Wed May 15 17:53:28 UTC 2019


#8093: Field Visibility Not Honored in PHP 7.1 & above
------------------------------+------------------------------
 Reporter:  brianbws          |       Owner:  (none)
     Type:  defect (bug)      |      Status:  new
 Priority:  normal            |   Milestone:  Awaiting Review
Component:  Extended Profile  |     Version:  4.3.0
 Severity:  normal            |  Resolution:
 Keywords:                    |
------------------------------+------------------------------

Comment (by brianbws):

 After some testing. I narrowed it down to here. In
 bp_xprofile_get_fields_by_visibility_levels() right after the first
 foreach.

 http://hookr.io/functions/bp_xprofile_get_fields_by_visibility_levels/

 In PHP 7.0.3: $user_visibility_levels=
 {{{
 Array ( [38] => public [39] => public [167] => adminsonly [58] => loggedin
 [59] => adminsonly [60] => adminsonly [61] => adminsonly [62] =>
 adminsonly [63] => adminsonly [64] => adminsonly [65] => adminsonly [68]
 => adminsonly [71] => adminsonly [72] => adminsonly [77] => adminsonly
 [78] => public [79] => public [80] => public [83] => public [86] => public
 [89] => public [92] => public [95] => public [96] => public [101] =>
 adminsonly [106] => adminsonly [107] => public [110] => public [113] =>
 public [114] => public [115] => public [149] => adminsonly [150] => public
 [154] => public [155] => public [156] => public [157] => public [163] =>
 adminsonly [164] => adminsonly [165] => adminsonly [166] => adminsonly
 [168] => adminsonly [169] => adminsonly [170] => adminsonly [171] =>
 adminsonly [172] => public [173] => public [174] => public [175] => public
 [176] => public [177] => public [178] => public [179] => public [184] =>
 public [185] => public [188] => public [189] => public [190] => public
 [191] => public [192] => public [193] => public [194] => public [195] =>
 public [196] => public [197] => public [198] => public [199] => public
 [200] => public [208] => public [209] => public )
 }}}

 In PHP 7.1.4 and PHP 7.2.0: $user_visibility_levels=
 {{{
  pp laaaaaaa a aa appp p p p p pp a ap p ppp ap pppp aaaaaaaaapppppppp pp
 ppppppppppppp pp
 }}}

 Note that $default_visibility_levels comes it correctly in all versions.

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


More information about the buddypress-trac mailing list