public function locate($key)
    {
        if (array_key_exists($key, $this->cache)) {
            return $this->cache[$key]['found'];
        }

        if ($this->locateLocal($key)) {
            return true;
        }

        if ($this->locateGlobal($key)) {
            return true;
        }

        $this->cache[$key] = [
            'found' => false,
            'config' => [],
            'path' => null,
        ];

        return false;
    }
public function locate($key)
    {
        if (array_key_exists($key, $this->cache)) {
            return $this->cache[$key]['found'];
        }

        if ($this->locateLocal($key)) {
            return true;
        }

        if ($this->locateGlobal($key)) {
            return true;
        }

        $this->cache[$key] = [
            'found' => false,
            'config' => [],
            'path' => null,
        ];

        return false;
    }
public function locate ( $ key ) { if ( array_key_exists ( $ key , $ this -> cache ) ) { return $ this -> cache [ $ key ] [ 'found' ] ; } if ( $ this -> locateLocal ( $ key ) ) { return true ; } if ( $ this -> locateGlobal ( $ key ) ) { return true ; } $ this -> cache [ $ key ] = [ 'found' => false , 'config' => [ ] , 'path' => null , ] ; return false ; }
Try to locate where is the config for the given key.

@param string $key

@return bool
Try to locate where is the config for the given key .