forked from ZwiiCMS-Team/ZwiiCampus
1.4.25 Corrige la fonction delete de la classe dot
This commit is contained in:
parent
cc92c90403
commit
595d068de2
@ -101,7 +101,7 @@ class Dot implements \ArrayAccess, \Iterator, \Countable
|
||||
}
|
||||
} else {
|
||||
// Iterate path
|
||||
$keys = explode('.', (string)$key);
|
||||
$keys = explode('.', (string) $key);
|
||||
if ($pop === true) {
|
||||
array_pop($keys);
|
||||
}
|
||||
@ -141,7 +141,7 @@ class Dot implements \ArrayAccess, \Iterator, \Countable
|
||||
} elseif (is_array($key)) {
|
||||
// Iterate array of paths
|
||||
foreach ($key as $k) {
|
||||
delete($k);
|
||||
self::deleteValue($array, $k);
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -199,7 +199,7 @@ class Dot implements \ArrayAccess, \Iterator, \Countable
|
||||
*/
|
||||
public function has($key)
|
||||
{
|
||||
$keys = explode('.', (string)$key);
|
||||
$keys = explode('.', (string) $key);
|
||||
$data = &$this->data;
|
||||
foreach ($keys as $key) {
|
||||
if (!isset($data[$key])) {
|
||||
@ -371,7 +371,7 @@ class Dot implements \ArrayAccess, \Iterator, \Countable
|
||||
*/
|
||||
public function isEmpty(): bool
|
||||
{
|
||||
return !(bool)count($this->data);
|
||||
return !(bool) count($this->data);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -391,7 +391,7 @@ class Dot implements \ArrayAccess, \Iterator, \Countable
|
||||
*/
|
||||
public function toJson()
|
||||
{
|
||||
return json_encode($this->data, JSON_UNESCAPED_UNICODE|JSON_PRETTY_PRINT);
|
||||
return json_encode($this->data, JSON_UNESCAPED_UNICODE | JSON_PRETTY_PRINT);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -51,7 +51,7 @@ class common
|
||||
const ACCESS_TIMER = 1800;
|
||||
|
||||
// Numéro de version
|
||||
const ZWII_VERSION = '1.4.24';
|
||||
const ZWII_VERSION = '1.4.25';
|
||||
|
||||
// URL autoupdate
|
||||
const ZWII_UPDATE_URL = 'https://forge.chapril.org/ZwiiCMS-Team/campus-update/raw/branch/master/';
|
||||
|
Loading…
Reference in New Issue
Block a user