public function saveListCurrentAcl(): int
    {
        $separate = $last = $this->loadListCurrentAcl();
        foreach ($this->listCurrentAcl as $item) {
            if (!isset($separate[$item['resource']])) {
                $separate[$item['resource']] = [];
            }

            if (!in_array($item['privilege'], $separate[$item['resource']])) {
                $separate[$item['resource']][] = $item['privilege'];
            }
        }
        // save only detect change
        if ($separate != $last) {
            return (int) file_put_contents($this->getPathListCurrentAcl(), Neon::encode($separate, Neon::BLOCK));
        }
        return 0;
    }