src/includes/classes/Core/Utils/DirCache.php
protected function sha1Keys(string $primary_key, $sub_key = null, array $args = []): array
    {
        if (!$primary_key || !$this->c::isSha1($primary_key)) {
            $primary_key = sha1($primary_key);
        }
        if (!isset($sub_key)) {
            return compact('primary_key');
        } else {
            if (!$sub_key || !$this->c::isSha1($sub_key)) {
                $sub_key = sha1((string) $sub_key);
            }
            return compact('primary_key', 'sub_key');
        }
    }
protected function sha1Keys(string $primary_key, $sub_key = null, array $args = []): array
    {
        if (!$primary_key || !$this->c::isSha1($primary_key)) {
            $primary_key = sha1($primary_key);
        }
        if (!isset($sub_key)) {
            return compact('primary_key');
        } else {
            if (!$sub_key || !$this->c::isSha1($sub_key)) {
                $sub_key = sha1((string) $sub_key);
            }
            return compact('primary_key', 'sub_key');
        }
    }
SHA-1 cache keys.

@since 170824.30708 Dir cache utils.

@param string          $primary_key Primary key.
@param string|int|null $sub_key     Sub-key to get.
@param array           $args        Any behavioral args.

@return array `[primary_key]` or `[primary_key, sub_key]`.