Skip to content

Commit

Permalink
Cleanup iac-v2
Browse files Browse the repository at this point in the history
  • Loading branch information
XanSmarty committed Oct 31, 2023
1 parent f74be41 commit d739657
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions examples/international-autocomplete-api/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@ func main() {
// https://smartystreets.com/docs/cloud/us-autocomplete-api#http-request-input-fields

lookup := &international_autocomplete.Lookup{
Country: "FRA",
AddressID: "OS0DMy8DPgNNTUpGTEhHAyA5LTo",
Locality: "Paris",
Country: "FRA",
Search: "Louis",
Locality: "Paris",
}

if err := client.SendLookupWithContext(context.Background(), lookup); err != nil {
Expand Down
2 changes: 1 addition & 1 deletion international-autocomplete-api/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -57,4 +57,4 @@ func buildRequest(lookup *Lookup) *http.Request {
}

// TODO support /lookup and /v2/lookup
const suggestURL = "/v2/lookup" // Remaining parts will be completed later by the sdk.BaseURLClient.
const suggestURL = "/lookup" // Remaining parts will be completed later by the sdk.BaseURLClient.
4 changes: 2 additions & 2 deletions international-autocomplete-api/client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -128,8 +128,8 @@ func (f *ClientFixture) TestAddressIDAppendsToURL() {

f.So(f.sender.request, should.NotBeNil)
f.So(f.sender.request.Method, should.Equal, "GET")
f.So(f.sender.request.URL.Path, should.Equal, suggestURL+"/"+f.input.AddressID)
f.So(f.sender.request.URL.String(), should.Equal, suggestURL+"/"+f.input.AddressID+"?country=FRA&max_results=5")
f.So(f.sender.request.URL.Path, should.Equal, suggestURL+"/thisisid")
f.So(f.sender.request.URL.String(), should.Equal, suggestURL+"/thisisid?country=FRA&max_results=5")
}

//////////////////////////////////////////////////////////////////
Expand Down
2 changes: 1 addition & 1 deletion wireup/options.go
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
package wireup

import (
international_autocomplete_deprecated "github.com/smartystreets/smartystreets-go-sdk/international-autocomplete-api-deprecated"
"net/http"
"time"

international_autocomplete "github.com/smartystreets/smartystreets-go-sdk/international-autocomplete-api"
international_autocomplete_deprecated "github.com/smartystreets/smartystreets-go-sdk/international-autocomplete-api-deprecated"
international_street "github.com/smartystreets/smartystreets-go-sdk/international-street-api"
"github.com/smartystreets/smartystreets-go-sdk/us-autocomplete-api"
autocomplete_pro "github.com/smartystreets/smartystreets-go-sdk/us-autocomplete-pro-api"
Expand Down

0 comments on commit d739657

Please sign in to comment.