Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions internal/api/router/endpoints.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
return
}

_, _ = w.Write(out)

Check failure on line 76 in internal/api/router/endpoints.go

View workflow job for this annotation

GitHub Actions / Lint and test

G705: XSS via taint analysis (gosec)
}

// getDeviceOpenConfig endpoint returns OpenConfig JSON for one or all devices.
Expand All @@ -98,7 +98,7 @@
w.WriteHeader(http.StatusInternalServerError)
return
}
_, _ = w.Write(cfg)

Check failure on line 101 in internal/api/router/endpoints.go

View workflow job for this annotation

GitHub Actions / Lint and test

G705: XSS via taint analysis (gosec)
}

// getDeviceIETFConfig endpoint returns Ietf JSON for one or all devices.
Expand All @@ -123,7 +123,7 @@
w.WriteHeader(http.StatusInternalServerError)
return
}
_, _ = w.Write(cfg)

Check failure on line 126 in internal/api/router/endpoints.go

View workflow job for this annotation

GitHub Actions / Lint and test

G705: XSS via taint analysis (gosec)
}

// getDeviceConfig endpoint returns Ietf & openconfig JSON for one or all devices.
Expand Down Expand Up @@ -197,8 +197,8 @@
w.Header().Set(contentType, applicationJSON)
select {
case m.newBuildRequest <- struct{}{}:
_, _ = w.Write([]byte("{\"message\": \"new build request received\""))
_, _ = w.Write([]byte("{\"message\": \"new build request received\"}"))
default:
_, _ = w.Write([]byte("{\"message\": \"a build request is already pending\""))
_, _ = w.Write([]byte("{\"message\": \"a build request is already pending\"}"))
}
}
Loading