This repository has been archived on 2022-08-17. You can view files and clone it, but cannot push or open issues or pull requests.
dex/schema/adminschema/util.go
2015-08-18 11:26:57 -07:00

14 lines
264 B
Go

package adminschema
import (
"net/http"
"strings"
)
func NewWithBasePath(client *http.Client, basePath string) (*Service, error) {
s, err := New(client)
if err == nil {
s.BasePath = strings.Replace(s.BasePath, "$ENDPOINT", basePath, 1)
}
return s, nil
}