Added check of parentPath in createParentCollection

This commit is contained in:
Justus Flerlage 2019-02-09 20:21:47 +01:00 committed by Vitalii
parent ff7f737904
commit e53b818e1b

View File

@ -165,5 +165,9 @@ func (c *Client) put(path string, stream io.Reader) int {
func (c *Client) createParentCollection(itemPath string) (err error) { func (c *Client) createParentCollection(itemPath string) (err error) {
parentPath := path.Dir(itemPath) parentPath := path.Dir(itemPath)
if parentPath == "." {
return nil
}
return c.MkdirAll(parentPath, 0755) return c.MkdirAll(parentPath, 0755)
} }