protected function getRelativePath($criteria): string
    {
        $criterion  = current($criteria);
        $components = explode('/', $criterion);

        if (count($components) < 2) {
            return '';
        }

        return implode('/', array_slice($components, 0, -1));
    }