Skip to content

Commit

Permalink
chore: Adds errcheck lint check (#42)
Browse files Browse the repository at this point in the history
  • Loading branch information
gruyaume authored Jan 4, 2024
1 parent 349dd6c commit 5524618
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -220,7 +220,7 @@ linters:
enable:
- gofmt
- govet
# - errcheck
- errcheck
- staticcheck
- unused
# - gosimple
Expand Down
5 changes: 4 additions & 1 deletion factory/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,10 @@ func (c *Config) updateConfig(commChannel chan *protos.NetworkSliceResponse) boo
sNssaiInPlmns := SupportedNssaiInPlmn{}
sNssaiInPlmns.PlmnId = plmn
nssai := new(models.Snssai)
val, _ := strconv.ParseInt(ns.Nssai.Sst, 10, 64)
val, err := strconv.ParseInt(ns.Nssai.Sst, 10, 64)
if err != nil {
logger.GrpcLog.Infoln("Error in parsing sst ", err)
}
nssai.Sst = int32(val)
nssai.Sd = ns.Nssai.Sd
logger.GrpcLog.Infoln("Slice Sst ", ns.Nssai.Sst)
Expand Down

0 comments on commit 5524618

Please sign in to comment.