Fixed API login response to work properly with PI-Hole v4.3.2

This commit is contained in:
Vincent Composieux 2019-09-29 15:24:27 +02:00
parent fe091ae1b6
commit d72e73ce97
No known key found for this signature in database
GPG Key ID: 7306974ABA6382AC
1 changed files with 1 additions and 1 deletions

View File

@ -119,7 +119,7 @@ func (c *Client) getPHPSessionID() (sessionID string) {
log.Printf("An error has occured during login to PI-Hole: %v", err)
}
if resp.StatusCode != http.StatusFound {
if resp.StatusCode != http.StatusOK {
log.Printf("Unable to login to PI-Hole, got a HTTP status code response '%d' instead of '%d'", resp.StatusCode, http.StatusFound)
os.Exit(1)
}