diff --git src/bp-core/bp-core-avatars.php src/bp-core/bp-core-avatars.php
index 8f264f607..18f9040ea 100644
|
|
function bp_core_fetch_avatar( $args = '' ) { |
456 | 456 | |
457 | 457 | // Use an alias to leave the param unchanged. |
458 | 458 | $avatar_classes = $params['class']; |
459 | | if ( ! is_array( $avatar_classes ) ) { |
| 459 | if ( is_null( $avatar_classes ) ) { |
| 460 | $avatar_classes = array(); |
| 461 | } elseif ( ! is_array( $avatar_classes ) ) { |
460 | 462 | $avatar_classes = explode( ' ', $avatar_classes ); |
461 | 463 | } |
462 | 464 | |
diff --git src/bp-core/classes/class-bp-core-bp-nav-backcompat.php src/bp-core/classes/class-bp-core-bp-nav-backcompat.php
index cf9c2b4df..ff9e874d3 100644
|
|
class BP_Core_BP_Nav_BackCompat implements ArrayAccess { |
60 | 60 | * @param mixed $offset Array offset. |
61 | 61 | * @param array $value Nav item. |
62 | 62 | */ |
| 63 | #[ReturnTypeWillChange] |
63 | 64 | public function offsetSet( $offset, $value ) { |
64 | 65 | _doing_it_wrong( |
65 | 66 | 'bp_nav', |
… |
… |
class BP_Core_BP_Nav_BackCompat implements ArrayAccess { |
94 | 95 | * @param mixed $offset Array offset. |
95 | 96 | * @return BP_Core_BP_Nav_BackCompat |
96 | 97 | */ |
| 98 | #[ReturnTypeWillChange] |
97 | 99 | public function offsetGet( $offset ) { |
98 | 100 | _doing_it_wrong( |
99 | 101 | 'bp_nav', |
… |
… |
class BP_Core_BP_Nav_BackCompat implements ArrayAccess { |
101 | 103 | '2.6.0' |
102 | 104 | ); |
103 | 105 | |
104 | | // if ( ! isset( $this->backcompat_nav[ $offset ] ) ) { |
105 | | $nav = $this->get_nav( $offset ); |
106 | | if ( $nav && isset( $nav[ $offset ] ) ) { |
107 | | $this->backcompat_nav[ $offset ] = new self( $nav[ $offset ] ); |
108 | | } |
109 | | // } |
| 106 | $nav = $this->get_nav( $offset ); |
| 107 | if ( $nav && isset( $nav[ $offset ] ) ) { |
| 108 | $this->backcompat_nav[ $offset ] = new self( $nav[ $offset ] ); |
| 109 | } |
110 | 110 | |
111 | 111 | return $this->backcompat_nav[ $offset ]; |
112 | 112 | } |
… |
… |
class BP_Core_BP_Nav_BackCompat implements ArrayAccess { |
119 | 119 | * @param mixed $offset Array offset. |
120 | 120 | * @return bool |
121 | 121 | */ |
| 122 | #[ReturnTypeWillChange] |
122 | 123 | public function offsetExists( $offset ) { |
123 | 124 | _doing_it_wrong( |
124 | 125 | 'bp_nav', |
… |
… |
class BP_Core_BP_Nav_BackCompat implements ArrayAccess { |
145 | 146 | * |
146 | 147 | * @param mixed $offset Array offset. |
147 | 148 | */ |
| 149 | #[ReturnTypeWillChange] |
148 | 150 | public function offsetUnset( $offset ) { |
149 | 151 | _doing_it_wrong( |
150 | 152 | 'bp_nav', |