mirror of
https://github.com/kamilwylegala/cakephp2-php8.git
synced 2024-11-15 03:18:26 +00:00
Fix Hash class callback callable pattern deprecated
This commit is contained in:
parent
e712b2da89
commit
7acb7c2938
1 changed files with 1 additions and 1 deletions
|
@ -561,7 +561,7 @@ class Hash {
|
||||||
* @return array Filtered array
|
* @return array Filtered array
|
||||||
* @link https://book.cakephp.org/2.0/en/core-utility-libraries/hash.html#Hash::filter
|
* @link https://book.cakephp.org/2.0/en/core-utility-libraries/hash.html#Hash::filter
|
||||||
*/
|
*/
|
||||||
public static function filter(array $data, $callback = array('self', '_filter')) {
|
public static function filter(array $data, $callback = array(Hash::class, '_filter')) {
|
||||||
foreach ($data as $k => $v) {
|
foreach ($data as $k => $v) {
|
||||||
if (is_array($v)) {
|
if (is_array($v)) {
|
||||||
$data[$k] = static::filter($v, $callback);
|
$data[$k] = static::filter($v, $callback);
|
||||||
|
|
Loading…
Reference in a new issue