Minor alignment of comments
This commit is contained in:
parent
96c10804ca
commit
699bee4dec
4 changed files with 6 additions and 5 deletions
|
|
@ -35,7 +35,7 @@ type Config struct {
|
|||
CCSPApplicationID string
|
||||
}
|
||||
|
||||
// API implements the Kia/Hyundai bluelink api.
|
||||
// Identity implements the Kia/Hyundai bluelink identity.
|
||||
// Based on https://github.com/Hacksore/bluelinky.
|
||||
type Identity struct {
|
||||
*request.Helper
|
||||
|
|
@ -45,7 +45,7 @@ type Identity struct {
|
|||
oauth2.TokenSource
|
||||
}
|
||||
|
||||
// NewIdentity creates a new BlueLink API
|
||||
// NewIdentity creates BlueLink Identity
|
||||
func NewIdentity(log *util.Logger, config Config) (*Identity, error) {
|
||||
v := &Identity{
|
||||
log: log,
|
||||
|
|
@ -292,7 +292,7 @@ func (v *Identity) exchangeCode(accCode string) (oauth.Token, error) {
|
|||
return token, err
|
||||
}
|
||||
|
||||
// Refresh implements token refresh
|
||||
// RefreshToken implements oauth.TokenRefresher
|
||||
func (v *Identity) RefreshToken(token *oauth2.Token) (*oauth2.Token, error) {
|
||||
headers := map[string]string{
|
||||
"Authorization": "Basic " + v.config.BasicToken,
|
||||
|
|
|
|||
|
|
@ -109,7 +109,7 @@ func (v *Ford) login() (oauth.Token, error) {
|
|||
return res, err
|
||||
}
|
||||
|
||||
// Refresh implements the oauth.TokenRefresher interface
|
||||
// Refresh implements oauth.TokenRefresher
|
||||
func (v *Ford) RefreshToken(token *oauth2.Token) (*oauth2.Token, error) {
|
||||
data := url.Values{
|
||||
"client_id": []string{"9fb503e0-715b-47e8-adfd-ad4b7770f73b"},
|
||||
|
|
|
|||
|
|
@ -19,6 +19,7 @@ type Identity struct {
|
|||
oauth2.TokenSource
|
||||
}
|
||||
|
||||
// NewIdentity creates Nissan identity
|
||||
func NewIdentity(log *util.Logger) *Identity {
|
||||
return &Identity{
|
||||
Helper: request.NewHelper(log),
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ type Identity struct {
|
|||
user, password string
|
||||
}
|
||||
|
||||
// NewIdentity creates a new Identity client
|
||||
// NewIdentity creates Porsche identity
|
||||
func NewIdentity(log *util.Logger, user, password string) *Identity {
|
||||
v := &Identity{
|
||||
log: log,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue