modifs.mineures sans commentaires
This commit is contained in:
parent
e8b7ca91af
commit
6c7cef322d
|
@ -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);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -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);
|
||||
}
|
||||
|
||||
|
|
|
@ -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;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue