N°5809 Update laminas/laminas-mail from 2.16.0 to 2.22.0

This commit is contained in:
Pierre Goiffon
2024-01-25 17:24:43 +01:00
parent f3d3ec6ef7
commit 0f39ea8ac7
146 changed files with 4426 additions and 8899 deletions

View File

@@ -35,22 +35,25 @@ abstract class ArrayUtils
{
/**
* Compatibility Flag for ArrayUtils::filter
*
* @deprecated
*/
public const ARRAY_FILTER_USE_BOTH = 1;
/**
* Compatibility Flag for ArrayUtils::filter
*
* @deprecated
*/
public const ARRAY_FILTER_USE_KEY = 2;
/**
* Test whether an array contains one or more string keys
*
* @param mixed $value
* @param bool $allowEmpty Should an empty array() return true
* @return bool
*/
public static function hasStringKeys($value, $allowEmpty = false)
public static function hasStringKeys(mixed $value, $allowEmpty = false)
{
if (! is_array($value)) {
return false;
@@ -66,11 +69,10 @@ abstract class ArrayUtils
/**
* Test whether an array contains one or more integer keys
*
* @param mixed $value
* @param bool $allowEmpty Should an empty array() return true
* @return bool
*/
public static function hasIntegerKeys($value, $allowEmpty = false)
public static function hasIntegerKeys(mixed $value, $allowEmpty = false)
{
if (! is_array($value)) {
return false;
@@ -93,11 +95,10 @@ abstract class ArrayUtils
* - a float: 2.2120, -78.150999
* - a string with float: '4000.99999', '-10.10'
*
* @param mixed $value
* @param bool $allowEmpty Should an empty array() return true
* @return bool
*/
public static function hasNumericKeys($value, $allowEmpty = false)
public static function hasNumericKeys(mixed $value, $allowEmpty = false)
{
if (! is_array($value)) {
return false;
@@ -126,11 +127,10 @@ abstract class ArrayUtils
* );
* </code>
*
* @param mixed $value
* @param bool $allowEmpty Is an empty list a valid list?
* @return bool
*/
public static function isList($value, $allowEmpty = false)
public static function isList(mixed $value, $allowEmpty = false)
{
if (! is_array($value)) {
return false;
@@ -168,11 +168,10 @@ abstract class ArrayUtils
* );
* </code>
*
* @param mixed $value
* @param bool $allowEmpty Is an empty array() a valid hash table?
* @return bool
*/
public static function isHashTable($value, $allowEmpty = false)
public static function isHashTable(mixed $value, $allowEmpty = false)
{
if (! is_array($value)) {
return false;
@@ -193,14 +192,15 @@ abstract class ArrayUtils
* non-strict check is implemented. if $strict = -1, the default in_array
* non-strict behaviour is used.
*
* @param mixed $needle
* @deprecated This method will be removed in version 4.0 of this component
*
* @param array $haystack
* @param int|bool $strict
* @return bool
*/
public static function inArray($needle, array $haystack, $strict = false)
public static function inArray(mixed $needle, array $haystack, $strict = false)
{
if (! $strict) {
if ((bool) $strict === false) {
if (is_int($needle) || is_float($needle)) {
$needle = (string) $needle;
}
@@ -318,7 +318,6 @@ abstract class ArrayUtils
/**
* @deprecated Since 3.2.0; use the native array_filter methods
*
* @param array $data
* @param callable $callback
* @param null|int $flag
* @return array