Fix: mc rm to error when nonempty directory is deleted (#2303)

Example: when mc rm play/testbucket/folder1 is attempted and directory
is nonempty, exit with an error message
This commit is contained in:
poornas
2017-11-09 18:28:53 -08:00
committed by Dee Koder
parent 014d09412a
commit 32a8f34f7d
+1 -1
View File
@@ -141,7 +141,7 @@ func removeSingle(url string, isIncomplete bool, isFake bool, older int) error {
errorIf(pErr.Trace(url), "Invalid argument `"+url+"`.")
return exitStatus(globalErrorExitStatus) // End of journey.
}
isFetchMeta := false
isFetchMeta := true
content, pErr := clnt.Stat(isIncomplete, isFetchMeta)
if pErr != nil {
errorIf(pErr.Trace(url), "Failed to remove `"+url+"`.")