Skip to content

Commit

Permalink
glangci-lint fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
vanillaSprinkles committed Jul 20, 2024
1 parent ea6ef82 commit 2be1719
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion proxmox/api/credentials.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,9 @@ func NewCredentials(username, password, otp, apiToken string, authTicket string,
case apiToken != "":
re := regexp.MustCompile(`^\S+@\S+!\S+=([a-zA-Z0-9-]+)$`)
if !re.MatchString(apiToken) {
return nil, errors.New("Must be a valid API token, e.g. 'USER@REALM!TOKENID=UUID'")
return nil, errors.New("Must be a valid API token, e.g. 'user@realm!tokenId=uuid'")
}

return &Credentials{
APIToken: &apiToken,
}, nil
Expand Down

0 comments on commit 2be1719

Please sign in to comment.