From 3efa862f72f16dad023801bb779605efea3b236f Mon Sep 17 00:00:00 2001 From: Dmitrii Fediuk Date: Thu, 6 Jun 2024 00:08:14 +0100 Subject: [PATCH] https://github.com/mage2pro/core/issues/379 --- app/code/local/Df/Core/lib/array/map.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/code/local/Df/Core/lib/array/map.php b/app/code/local/Df/Core/lib/array/map.php index 17af35223a..a082973185 100644 --- a/app/code/local/Df/Core/lib/array/map.php +++ b/app/code/local/Df/Core/lib/array/map.php @@ -66,7 +66,8 @@ function df_map($a1, $a2, $pAppend = [], $pPrepend = [], int $keyPosition = 0, b # https://3v4l.org/3O92j # https://php.net/manual/migration71.new-features.php#migration71.new-features.symmetric-array-destructuring # https://stackoverflow.com/a/28233499 - list($a, $f) = dfaf($a1, $a2); /** @var iterable $a */ /** @var callable $f */ + # 2024-06-06 "Use the «Symmetric array destructuring» PHP 7.1 feature": https://github.com/mage2pro/core/issues/379 + [$a, $f] = dfaf($a1, $a2); /** @var iterable $a */ /** @var callable $f */ /** @var array(int|string => mixed) $r */ if (!$pAppend && !$pPrepend && 0 === $keyPosition && !$returnKey) { $r = array_map($f, df_ita($a));