diff --git a/restapi.go b/restapi.go index c108369..9eead00 100644 --- a/restapi.go +++ b/restapi.go @@ -1559,6 +1559,13 @@ func (s *Session) Gateway() (gateway string, err error) { } gateway = temp.URL + + // Ensure the gateway always has a trailing slash. + // MacOS will fail to connect if we add query params without a trailing slash on the base domain. + if !strings.HasSuffix(gateway, "/") { + gateway += "/" + } + return }