1
0
Fork 0

Include resp body in error

main v0.12.2
Jordan Hotmann 2023-11-27 16:47:50 -07:00
parent 66cac3ca0c
commit 369bdd8f2b
No known key found for this signature in database
GPG Key ID: 01B504170C2A2EA3
1 changed files with 1 additions and 1 deletions

View File

@ -38,7 +38,7 @@ func (c *QbittorrentClient) Login(user string, pass string) error {
authCookie := resp.Header().Get("set-cookie")
if authCookie == "" {
return fmt.Errorf("auth cookie not found. Headers: %+v", resp.Header())
return fmt.Errorf("auth cookie not found.\nResponse: %s\nHeaders: %+v", resp.Body(), resp.Header())
}
first := strings.Split(authCookie, ";")[0]