mirror of
https://github.com/minio/mc.git
synced 2025-11-10 13:42:32 +03:00
mirror: For non-s3 make sure we copy and exit properly. (#1995)
This commit is contained in:
@@ -49,11 +49,8 @@ func checkCopySyntax(ctx *cli.Context) {
|
||||
// Check if bucket name is passed for URL type arguments.
|
||||
url := newClientURL(tgtURL)
|
||||
if url.Host != "" {
|
||||
// This check is for type URL.
|
||||
if !isURLVirtualHostStyle(url.Host) {
|
||||
if url.Path == string(url.Separator) {
|
||||
fatalIf(errInvalidArgument().Trace(), fmt.Sprintf("Target ‘%s’ does not contain bucket name.", tgtURL))
|
||||
}
|
||||
if url.Path == string(url.Separator) {
|
||||
fatalIf(errInvalidArgument().Trace(), fmt.Sprintf("Target ‘%s’ does not contain bucket name.", tgtURL))
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user