Skip to content

Commit

Permalink
fixing things
Browse files Browse the repository at this point in the history
  • Loading branch information
Claire.Nicholas authored and Claire.Nicholas committed Dec 22, 2023
1 parent 9694b4e commit dc495ae
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions api/build/restart.go
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,11 @@ func RestartBuild(c *gin.Context) {
build := append(d.Builds, b)

d.SetBuilds(build)

database.FromContext(c).UpdateDeployment(c, d)

Check failure on line 350 in api/build/restart.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] api/build/restart.go#L350

Error return value of `(github.com/go-vela/server/database/deployment.DeploymentInterface).UpdateDeployment` is not checked (errcheck)
Raw output
api/build/restart.go:350:42: Error return value of `(github.com/go-vela/server/database/deployment.DeploymentInterface).UpdateDeployment` is not checked (errcheck)
	database.FromContext(c).UpdateDeployment(c, d)
	                                        ^

Check failure on line 350 in api/build/restart.go

View workflow job for this annotation

GitHub Actions / full-review

Error return value of `(github.com/go-vela/server/database/deployment.DeploymentInterface).UpdateDeployment` is not checked (errcheck)

Check failure on line 350 in api/build/restart.go

View workflow job for this annotation

GitHub Actions / diff-review

Error return value of `(github.com/go-vela/server/database/deployment.DeploymentInterface).UpdateDeployment` is not checked (errcheck)
if err != nil {

Check failure on line 351 in api/build/restart.go

View workflow job for this annotation

GitHub Actions / golangci

[golangci] api/build/restart.go#L351

if statements should only be cuddled with assignments (wsl)
Raw output
api/build/restart.go:351:2: if statements should only be cuddled with assignments (wsl)
	if err != nil {
	^
logger.Errorf("unable to set update deployment for build %s: %v", entry, err)
}

// send API call to set the status on the commit
err = scm.FromContext(c).Status(ctx, u, b, r.GetOrg(), r.GetName())
Expand Down

0 comments on commit dc495ae

Please sign in to comment.