Added source and user marks to opportunities type. Any ignored errors are deferred to //nolint with a comment instead of being silently dropped
This commit is contained in:
1 parent
6e6dec68c0
commit
9b0e6dccfe
7 files changed
+65
-4
No files matched your search
@@ -65,7 +65,8 @@ func decodeCursor(c string) (int, error) {
|
||||
func badRequest(w http.ResponseWriter, msg string) {
|
||||
w.Header().Set("Content-Type", "application/json")
|
||||
w.WriteHeader(http.StatusBadRequest)
|
||||
_ = json.NewEncoder(w).Encode(map[string]string{"error": msg}) // the client has gone
|
||||
body := map[string]string{"error": msg}
|
||||
json.NewEncoder(w).Encode(body) //nolint:errcheck,gosec // the client may have gone; nothing to do
|
||||
}
|
||||
|
||||
// parseTime reads a query timestamp. Values without an offset (the documented
|
||||
|
||||
Reference in new issue
Block a user