protected function ensureSubDirs($directory, Config $config = null)
    {
        $config = $config ?: new Config();

        return $this->createDir(Util::dirname($directory), $config);
    }
protected function ensureSubDirs($directory, Config $config = null)
    {
        $config = $config ?: new Config();

        return $this->createDir(Util::dirname($directory), $config);
    }
protected function ensureSubDirs ( $ directory , Config $ config = null ) { $ config = $ config ? : new Config ( ) ; return $ this -> createDir ( Util :: dirname ( $ directory ) , $ config ) ; }
Ensures that the sub-directories of a directory exist.

@param string      $directory The directory.
@param Config|null $config    Optionl configuration.

@return bool True on success, false on failure.
Ensures that the sub - directories of a directory exist .