1
0
mirror of https://github.com/minio/mc.git synced 2025-07-30 07:23:03 +03:00

Remove error statement in mc mirror (#2500)

mc mirror complains about extra file in destination,
but this is not an error so removed the error message.

Fixes: #2470
This commit is contained in:
Ashish Kumar Sinha
2018-08-02 22:45:54 +05:30
committed by Nitish Tiwari
parent 480bc8aa2a
commit 9998e077df
3 changed files with 1 additions and 12 deletions

View File

@ -590,7 +590,7 @@ func (mj *mirrorJob) mirror(ctx context.Context, cancelMirror context.CancelFunc
PathInsufficientPermission, ObjectOnGlacier:
errorIf(err, "Unable to perform a mirror action.")
continue
case deleteNotAllowedErr, overwriteNotAllowedErr:
case overwriteNotAllowedErr:
errorIf(err, "Unable to perform a mirror action.")
continue
}

View File

@ -178,10 +178,6 @@ func deltaSourceTarget(sourceURL, targetURL string, isFake, isOverwrite, isRemov
}
case differInSecond:
if !isRemove && !isFake {
// Object removal not allowed if --remove is not set.
URLsCh <- URLs{
Error: errDeleteNotAllowed(diffMsg.SecondURL),
}
continue
}
URLsCh <- URLs{

View File

@ -103,13 +103,6 @@ var errOverWriteNotAllowed = func(URL string) *probe.Error {
return probe.NewError(overwriteNotAllowedErr(errors.New(msg)))
}
type deleteNotAllowedErr error
var errDeleteNotAllowed = func(URL string) *probe.Error {
msg := "Delete not allowed for `" + URL + "`. Use `--remove` to override this behavior."
return probe.NewError(deleteNotAllowedErr(errors.New(msg)))
}
type sourceIsDirErr error
var errSourceIsDir = func(URL string) *probe.Error {