mirror of
https://github.com/WordPress/five-for-the-future.git
synced 2025-04-16 16:43:42 +03:00
Contributors: Apply ??
before array cast, to avoid PHP notice.
See 8c28881
This commit is contained in:
parent
cd36902bb5
commit
9c0d1371f3
|
@ -59,7 +59,7 @@ function get_all_xprofile_contributor_hours_teams() : array {
|
|||
|
||||
$user->user_id = absint( $user->user_id );
|
||||
$user->hours_per_week = absint( $user->hours_per_week ?? 0 );
|
||||
$user->team_names = (array) $user->team_names ?? array();
|
||||
$user->team_names = (array) ( $user->team_names ?? array() );
|
||||
|
||||
if ( 0 >= $user->hours_per_week || empty( $user->team_names ) ) {
|
||||
unset( $users[ $user_index ] );
|
||||
|
|
Loading…
Reference in a new issue