Skip to content

Commit

Permalink
refactor(protocol): decoder error 'should not be capitalized'
Browse files Browse the repository at this point in the history
staticcheck reports:
> protocol/decoder.go:19:10: error strings should not be capitalized (ST1005)
  • Loading branch information
robert-wallis committed Jul 16, 2024
1 parent 7dee1ee commit e263dbd
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion protocol/assertion_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ func TestParseCredentialRequestResponse(t *testing.T) {
errString: "Parse error for Assertion",
errType: "invalid_request",
errDetails: "Parse error for Assertion",
errInfo: "The body contains trailing data",
errInfo: "the body contains trailing data",
},
}

Expand Down
2 changes: 1 addition & 1 deletion protocol/credential_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ func TestParseCredentialCreationResponse(t *testing.T) {
errString: "Parse error for Registration",
errType: "invalid_request",
errDetails: "Parse error for Registration",
errInfo: "The body contains trailing data",
errInfo: "the body contains trailing data",
},
}

Expand Down
2 changes: 1 addition & 1 deletion protocol/decoder.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ func decodeBody(body io.Reader, v any) (err error) {
_, err = decoder.Token()

if !errors.Is(err, io.EOF) {
return errors.New("The body contains trailing data")
return errors.New("the body contains trailing data")
}

return nil
Expand Down

0 comments on commit e263dbd

Please sign in to comment.