Skip to content

Commit

Permalink
Fix the code scan reported issue (vmware-tanzu#674)
Browse files Browse the repository at this point in the history
  • Loading branch information
mpanchajanya authored Feb 7, 2024
1 parent 3197c65 commit 4578fb8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/command/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -221,9 +221,9 @@ func setLoggerVerbosity() {
// Configure the log level if env variable TANZU_CLI_LOG_LEVEL is set
logLevel := os.Getenv(log.EnvTanzuCLILogLevel)
if logLevel != "" {
logValue, err := strconv.Atoi(logLevel)
logValue, err := strconv.ParseInt(logLevel, 10, 32)
if err == nil {
log.SetVerbosity(int32(logValue)) //nolint:gosec
log.SetVerbosity(int32(logValue))
}
}
}
Expand Down

0 comments on commit 4578fb8

Please sign in to comment.