Skip to content

Commit 83a76a9

Browse files
author
Sergey Vilgelm
committed
GolangCi enable comments validation
1 parent 33311f5 commit 83a76a9

File tree

3 files changed

+6
-1
lines changed

3 files changed

+6
-1
lines changed

.golangci.yml

+3
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,12 @@ linters-settings:
3333
simplify: true
3434

3535
issues:
36+
exclude-use-default: false
3637
exclude-rules:
3738
- path: _test\.go
3839
linters:
3940
- gocyclo
4041
- dupl
4142
- gosec
43+
exclude:
44+
- should have a package comment

errors.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ func (e HTTPErrorResponse) String() string {
3232
return res.String()
3333
}
3434

35-
// HasError validates that error is not emptyp
35+
// NotEmpty validates that error is not emptyp
3636
func (e HTTPErrorResponse) NotEmpty() bool {
3737
return len(e.Error) > 0 || len(e.Message) > 0 || len(e.Description) > 0
3838
}

models.go

+2
Original file line numberDiff line numberDiff line change
@@ -255,6 +255,8 @@ type GetGroupsParams struct {
255255
BriefRepresentation *bool `json:"briefRepresentation,string,omitempty"`
256256
}
257257

258+
// MarshalJSON is a custom json marshaling function to automatically set the Full and BriefRepresentation properties
259+
// for backward compatibility
258260
func (obj GetGroupsParams) MarshalJSON() ([]byte, error) {
259261
type Alias GetGroupsParams
260262
a := (Alias)(obj)

0 commit comments

Comments
 (0)