···3030 return &http.Client{Jar: jar}, nil
3131}
32323333-// saveCookies serializes the cookies and saves them to the system keyring
3434-func saveCookies(cookies []*http.Cookie, host string, handle string) error {
3333+// SaveCookies serializes the cookies and saves them to the system keyring
3434+func SaveCookies(cookies []*http.Cookie, host string, handle string) error {
3535+ if len(cookies) == 0 {
3636+ return nil
3737+ }
3538 data, err := json.Marshal(cookies)
3639 if err != nil {
3740 return err