Skip to content

Commit 7cef3b0

Browse files
authored
adding omitempty to request object (#15031)
1 parent 1546284 commit 7cef3b0

File tree

2 files changed

+5
-2
lines changed

2 files changed

+5
-2
lines changed

api/server/structs/endpoints_beacon.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,8 @@ type GetBlockHeaderResponse struct {
7878
}
7979

8080
type GetValidatorsRequest struct {
81-
Ids []string `json:"ids"`
82-
Statuses []string `json:"statuses"`
81+
Ids []string `json:"ids,omitempty"`
82+
Statuses []string `json:"statuses,omitempty"`
8383
}
8484

8585
type GetValidatorsResponse struct {
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
### Changed
2+
3+
- changed request object for `POST /eth/v1/beacon/states/head/validators` to omit the field if empty for satisfying other clients.

0 commit comments

Comments
 (0)