Skip to content

Commit 03c5f0e

Browse files
authored
Add required query param for - resolution
Bug fix for API resource https://docs.sentry.io/api/projects/get-project-stats/ If make a request without a parameter "resolution", an error with 500 code will be received in response
1 parent be9fc06 commit 03c5f0e

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

stat.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,11 @@ func (o *statRequest) ToQueryString() string {
2727
query.Add("stat", string(o.Stat))
2828
query.Add("since", strconv.FormatInt(o.Since, 10))
2929
query.Add("until", strconv.FormatInt(o.Until, 10))
30+
31+
if o.Resolution != nil {
32+
query.Add("resolution", string(*o.Resolution))
33+
}
34+
3035
return query.Encode()
3136
}
3237

0 commit comments

Comments
 (0)