Made the url used to check the token a config option
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
@@ -19,7 +19,7 @@ type Home struct {
|
||||
}
|
||||
|
||||
// Auto populate and update the device list
|
||||
func New(username string, credentials config.Credentials) *Home {
|
||||
func New(username string, credentials config.Credentials, oauthUrl string) *Home {
|
||||
home := &Home{Username: username, Devices: make(map[device.InternalName]device.Basic)}
|
||||
|
||||
homegraphService, err := homegraph.NewService(context.Background(), option.WithCredentialsJSON(credentials))
|
||||
@@ -27,7 +27,7 @@ func New(username string, credentials config.Credentials) *Home {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
home.Service = google.NewService(home, homegraphService)
|
||||
home.Service = google.NewService(home, homegraphService, oauthUrl)
|
||||
|
||||
return home
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user