1
0
mirror of https://github.com/minio/mc.git synced 2025-11-26 20:03:05 +03:00

More flags check in replicate add command (#3503)

This commit is contained in:
Anis Elleuch
2020-11-25 19:20:43 +01:00
committed by GitHub
parent bf2f7f0292
commit 25fd302af6
2 changed files with 8 additions and 0 deletions

View File

@@ -105,6 +105,12 @@ func checkReplicateAddSyntax(ctx *cli.Context) {
if len(ctx.Args()) != 1 {
cli.ShowCommandHelpAndExit(ctx, "add", 1) // last argument is exit code
}
if ctx.String("arn") == "" {
fatal(errDummy().Trace(), "--arn flag needs to be specified.")
}
if ctx.String("remote-bucket") == "" {
fatal(errDummy().Trace(), "--remote-bucket flag needs to be specified.")
}
}
type replicateAddMessage struct {