Fix authz flag (#787)
* Fix authz flag * add changelog bug fix for authz flag Co-authored-by: Jeff Mitchell <jeffrey.mitchell@gmail.com>
This commit is contained in:
1 parent
a37ba007f2
commit
a7fca44809
2 files changed
+11
-6
No files matched your search
@@ -257,12 +257,15 @@ func (c *Command) Run(args []string) (retCode int) {
|
||||
}
|
||||
|
||||
switch {
|
||||
case c.flagAuthzToken != "" && c.flagTargetId != "":
|
||||
c.UI.Error(`-target-id and -authz-token cannot both be specified`)
|
||||
return 1
|
||||
case c.flagAuthzToken != "" && c.flagTargetName != "":
|
||||
c.UI.Error(`-target-name and -authz-token cannot both be specified`)
|
||||
return 1
|
||||
case c.flagAuthzToken != "":
|
||||
switch {
|
||||
case c.flagTargetId != "":
|
||||
c.UI.Error(`-target-id and -authz-token cannot both be specified`)
|
||||
return 1
|
||||
case c.flagTargetName != "":
|
||||
c.UI.Error(`-target-name and -authz-token cannot both be specified`)
|
||||
return 1
|
||||
}
|
||||
default:
|
||||
if c.flagTargetId == "" &&
|
||||
(c.flagTargetName == "" ||
|
||||
|
||||
Reference in new issue
Block a user