Fix some small lint errors

Signed-off-by: Ryan Richard <richardry@vmware.com>
This commit is contained in:
Margo Crawford 2021-02-24 16:09:15 -08:00 committed by Ryan Richard
parent aee7a7a72b
commit 975d493b8a
4 changed files with 5 additions and 3 deletions

View File

@ -24,6 +24,8 @@ func (c *conciergeMode) String() string {
switch *c {
case modeImpersonationProxy:
return "ImpersonationProxy"
case modeTokenCredentialRequestAPI:
return "TokenCredentialRequestAPI"
default:
return "TokenCredentialRequestAPI"
}

View File

@ -1,3 +1,6 @@
// Copyright 2021 the Pinniped contributors. All Rights Reserved.
// SPDX-License-Identifier: Apache-2.0
package cmd
import (

View File

@ -190,7 +190,6 @@ func runOIDCLogin(cmd *cobra.Command, deps oidcLoginCommandDeps, flags oidcLogin
// The exact behavior depends on in which mode the Concierge is operating.
switch flags.conciergeMode {
case modeTokenCredentialRequestAPI:
// do a credential exchange request
cred, err := deps.exchangeToken(ctx, concierge, token.IDToken.Token)

View File

@ -122,7 +122,6 @@ func runStaticLogin(out io.Writer, deps staticLoginDeps, flags staticLoginParams
// If the concierge is enabled, we need to do extra steps.
switch flags.conciergeMode {
case modeTokenCredentialRequestAPI:
// do a credential exchange request
ctx, cancel := context.WithTimeout(context.Background(), 30*time.Second)
@ -146,5 +145,4 @@ func runStaticLogin(out io.Writer, deps staticLoginDeps, flags staticLoginParams
default:
return fmt.Errorf("unsupported Concierge mode %q", flags.conciergeMode.String())
}
}