modifs.mineures sans commentaires

This commit is contained in:
Jephté Clain 2024-04-05 08:51:14 +04:00
parent e8b7ca91af
commit 6c7cef322d
3 changed files with 5 additions and 5 deletions

View File

@ -73,11 +73,11 @@ class akey {
static final function merge(&$array, $key, $merge): void {
if ($array instanceof ArrayAccess) {
$value = $array->offsetGet($key);
cl::merge($value, $merge);
$value = cl::merge($value, $merge);
$array->offsetSet($key, $value);
} else {
cl::ensure_array($array);
cl::merge($array[$key], $merge);
$array[$key] = cl::merge($array[$key], $merge);
}
}

View File

@ -107,7 +107,7 @@ class mprop {
*/
static final function merge(object $object, string $property, $array): void {
$values = cl::with(self::get($object, $property));
cl::merge($values, cl::with($array));
$values = cl::merge($values, cl::with($array));
self::set($object, $property, $values);
}

View File

@ -113,7 +113,7 @@ class oprop {
$p = $c->getProperty($property);
$p->setAccessible(true);
$values = cl::with($p->getValue($object));
cl::merge($values, cl::with($array));
$values = cl::merge($values, cl::with($array));
$p->setValue($object, $values);
} catch (ReflectionException $e) {
if (property_exists($object, $property)) {
@ -121,7 +121,7 @@ class oprop {
} else {
$values = [];
}
cl::merge($values, cl::with($array));
$values = cl::merge($values, cl::with($array));
$object->$property = $values;
}
}