mirror of
https://github.com/gravitational/teleport
synced 2024-10-19 16:53:57 +00:00
fix: Ignore staticcheck false positive on darwin (#28038)
This commit is contained in:
parent
6ed1a58e1f
commit
ec8594f96d
|
@ -57,7 +57,9 @@ func SolveTPMAuthnDeviceChallenge(challenge *devicepb.TPMAuthenticateDeviceChall
|
|||
// HandleTPMActivateCredential completes the credential activation part of an
|
||||
// enrollment challenge. This is usually called in an elevated process that's
|
||||
// created by SolveTPMEnrollChallenge.
|
||||
func HandleTPMActivateCredential(encryptedCredential string, encryptedCredentialSecret string) error {
|
||||
//
|
||||
//nolint:staticcheck // HandleTPMActivateCredential works depending on the platform.
|
||||
func HandleTPMActivateCredential(encryptedCredential, encryptedCredentialSecret string) error {
|
||||
return handleTPMActivateCredential(encryptedCredential, encryptedCredentialSecret)
|
||||
}
|
||||
|
||||
|
|
|
@ -166,9 +166,11 @@ type deviceActivateCredentialCommand struct {
|
|||
}
|
||||
|
||||
func (c *deviceActivateCredentialCommand) run(cf *CLIConf) error {
|
||||
//nolint:staticcheck // HandleTPMActivateCredential works depending on the platform.
|
||||
err := dtnative.HandleTPMActivateCredential(
|
||||
c.encryptedCredential, c.encryptedCredentialSecret,
|
||||
)
|
||||
//nolint:staticcheck // `err` can indeed be nil.
|
||||
if cf.Debug && err != nil {
|
||||
// On error, wait for user input before executing. This is because this
|
||||
// opens in a second window. If we return the error immediately, then
|
||||
|
|
Loading…
Reference in a new issue