Skip to content
This repository has been archived by the owner on Feb 27, 2023. It is now read-only.

Commit

Permalink
Strip tailing slash from base url (#1)
Browse files Browse the repository at this point in the history
  • Loading branch information
vearutop authored Dec 10, 2020
1 parent 6dc25f0 commit 3e04c4f
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ require (
github.com/hashicorp/go-uuid v1.0.2 // indirect
github.com/stretchr/testify v1.6.1
github.com/swaggest/assertjson v1.5.2
github.com/swaggest/rest v0.1.5
github.com/swaggest/rest v0.1.6
golang.org/x/net v0.0.0-20201202161906-c7110b5ffcbb // indirect
golang.org/x/sys v0.0.0-20201204225414-ed752295db88 // indirect
)
4 changes: 2 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,8 @@ github.com/swaggest/refl v0.1.2/go.mod h1:kmYWhxNEvjfRDdMRqpaR/vLULk/SotJs9HFUCI
github.com/swaggest/refl v0.1.3/go.mod h1:kmYWhxNEvjfRDdMRqpaR/vLULk/SotJs9HFUCIVMK8o=
github.com/swaggest/refl v0.1.6 h1:z5drruoOSfWoB4aPuL22cMB5suLuxXS22oQkpTQ093o=
github.com/swaggest/refl v0.1.6/go.mod h1:XqZZZ8i6hptbvd3A8pvXkF0ontg0Wziqe7OFAnvAZMk=
github.com/swaggest/rest v0.1.5 h1:agXTVTcNgbged8U6woxHeDxT/Q7xBEWtjKJCgGLAe8g=
github.com/swaggest/rest v0.1.5/go.mod h1:TjP5yVyaWYCp7V3RktAc/94reXuqJTt5GjwxdKonWeo=
github.com/swaggest/rest v0.1.6 h1:ARfX0OAkfAC9hfgDoIH9737yUl2zUxtA3SzVPXqhWLs=
github.com/swaggest/rest v0.1.6/go.mod h1:TjP5yVyaWYCp7V3RktAc/94reXuqJTt5GjwxdKonWeo=
github.com/swaggest/swgen v0.6.20/go.mod h1:ipkZNfwztgRfbOWUllLZawfmxXprT8flqNJO9XhoMwM=
github.com/swaggest/swgen v0.6.23/go.mod h1:gj2yCLONy3kosKjwRtQeT5O9qqlhUvXAiDnbVwBUNFM=
github.com/swaggest/swgen v0.6.27/go.mod h1:tQLsoQVLcvtAMzNbm26JbWXDHZM4BBRuI5nemk3gEDw=
Expand Down
2 changes: 2 additions & 0 deletions local.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,8 @@ func NewLocal(baseURL string) *Local {
baseURL = "http://" + baseURL
}

baseURL = strings.TrimRight(baseURL, "/")

return &Local{
Client: resttest.NewClient(baseURL),
}
Expand Down

0 comments on commit 3e04c4f

Please sign in to comment.