Skip to content
This repository has been archived by the owner on Apr 11, 2019. It is now read-only.

Commit

Permalink
use user.login instead of user.authenticate, its no longer supported …
Browse files Browse the repository at this point in the history
…with ZABBIX 2.4 and user.login is avaible since ZABBIX 1.8
  • Loading branch information
floriankoch committed Oct 10, 2014
1 parent e8c8ee8 commit bdebf8c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions base.go
Original file line number Diff line number Diff line change
Expand Up @@ -129,10 +129,10 @@ func (api *API) CallWithError(method string, params interface{}) (response Respo
return
}

// Calls "user.authenticate" API method and fills api.Auth field.
// Calls "user.login" API method and fills api.Auth field.
func (api *API) Login(user, password string) (auth string, err error) {
params := map[string]string{"user": user, "password": password}
response, err := api.CallWithError("user.authenticate", params)
response, err := api.CallWithError("user.login", params)
if err != nil {
return
}
Expand Down

0 comments on commit bdebf8c

Please sign in to comment.