[buddypress-trac] [BuddyPress Trac] #8503: PHP8 multi-byte safety warning

buddypress-trac noreply at wordpress.org
Thu Jul 15 09:57:26 UTC 2021


#8503: PHP8 multi-byte safety warning
------------------------------+---------------------
 Reporter:  ionvv             |       Owner:  (none)
     Type:  defect (bug)      |      Status:  new
 Priority:  normal            |   Milestone:  8.1.0
Component:  Extended Profile  |     Version:  8.0.0
 Severity:  normal            |  Resolution:
 Keywords:  has-patch         |
------------------------------+---------------------

Comment (by imath):

 In [changeset:"13011" 13011]:
 {{{
 #!CommitTicketReference repository="" revision="13011"
 Avoid a PHP8 warning when xProfile user visibility levels are empty

 When the record does not exist yet into the usermeta table, getting the
 `'bp_xprofile_visibility_levels'` usermeta returns an empty string while
 we're expecting an array. As we use the expected array to reset the
 visibility level if the administrator enforced a specific visibility to
 the field, it's causing the PHP8 warning. To fix it, we are now casting
 the `'bp_xprofile_visibility_levels'` usermeta as soon as we get it.

 Props johnjamesjacoby

 See #8503 (branch 8.0)
 }}}

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


More information about the buddypress-trac mailing list