Skip to content

Commit b4dbc8b

Browse files
fix: update validation tags for TimeBoundariesRequest fields (#335)
Co-authored-by: Shivam Nagar <124123645+Shivam-nagar23@users.noreply.github.com>
1 parent 16f8a79 commit b4dbc8b

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

common-lib/utils/TimeUtils.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -158,9 +158,9 @@ func (timeRange *TimeRangeRequest) ParseAndValidateTimeRange() (*TimeRangeReques
158158

159159
// TimeBoundariesRequest represents the request for time boundary frames
160160
type TimeBoundariesRequest struct {
161-
TimeWindowBoundaries []string `json:"timeWindowBoundaries" schema:"timeWindowBoundaries" validate:"omitempty, min=1"`
162-
TimeWindow *TimeWindows `json:"timeWindow" schema:"timeWindow" validate:"omitempty, oneof=week month quarter year"` // week, month, quarter, year
163-
Iterations int `json:"iterations" schema:"iterations" validate:"omitempty, min=1"`
161+
TimeWindowBoundaries []string `json:"timeWindowBoundaries" schema:"timeWindowBoundaries" validate:"omitempty,min=1"`
162+
TimeWindow *TimeWindows `json:"timeWindow" schema:"timeWindow" validate:"omitempty,oneof=week month quarter year"` // week, month, quarter, year
163+
Iterations int `json:"iterations" schema:"iterations" validate:"omitempty,min=1"`
164164
}
165165

166166
// TimeWindowBoundaries represents the start and end times for a time window

0 commit comments

Comments
 (0)