Skip to content

Commit

Permalink
Format
Browse files Browse the repository at this point in the history
  • Loading branch information
richardm-stripe committed Dec 12, 2023
1 parent 79d3cc3 commit 6d40270
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
10 changes: 5 additions & 5 deletions stripe.go
Original file line number Diff line number Diff line change
Expand Up @@ -283,10 +283,10 @@ type BackendImplementation struct {
type metricsResponseSetter struct {
LastResponseSetter
backend *BackendImplementation
params *Params
params *Params
}

func (s *metricsResponseSetter) SetLastResponse (response *APIResponse) {
func (s *metricsResponseSetter) SetLastResponse(response *APIResponse) {
var usage []string
if s.params != nil {
usage = s.params.usage
Expand All @@ -301,7 +301,7 @@ func (s *metricsResponseSetter) UnmarshalJSON(b []byte) error {

type streamingLastResponseSetterWrapper struct {
StreamingLastResponseSetter
f func(*StreamingAPIResponse)
f func(*StreamingAPIResponse)
}

func (l *streamingLastResponseSetterWrapper) SetLastResponse(response *StreamingAPIResponse) {
Expand Down Expand Up @@ -438,8 +438,8 @@ func (s *BackendImplementation) CallRaw(method, path, key string, form *form.Val

responseSetter := metricsResponseSetter{
LastResponseSetter: v,
backend: s,
params: params,
backend: s,
params: params,
}

if err := s.Do(req, bodyBuffer, &responseSetter); err != nil {
Expand Down
4 changes: 2 additions & 2 deletions stripe_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -512,7 +512,7 @@ func TestCall_TelemetryEnabled(t *testing.T) {
case 2:
assert.True(t, len(telemetryStr) > 0, "telemetryStr should not be empty")

var telemetry requestTelemetry
var telemetry requestTelemetry
// the telemetry should properly unmarshal into RequestTelemetry
err := json.Unmarshal([]byte(telemetryStr), &telemetry)
assert.NoError(t, err)
Expand Down Expand Up @@ -552,7 +552,7 @@ func TestCall_TelemetryEnabled(t *testing.T) {

type myCreateParams struct {
Params `form:"*"`
Foo string `form:"foo"`
Foo string `form:"foo"`
}
params := &myCreateParams{
Foo: "bar",
Expand Down

0 comments on commit 6d40270

Please sign in to comment.