1
0
Fork 0
mirror of https://github.com/miniflux/v2.git synced 2025-09-05 18:41:01 +00:00

Add new fields for feed username/password

This commit is contained in:
Frédéric Guillot 2018-06-19 22:58:29 -07:00
parent 261695c14c
commit bddca15b69
27 changed files with 203 additions and 68 deletions

View file

@ -27,10 +27,11 @@ var (
)
// FindSubscriptions downloads and try to find one or more subscriptions from an URL.
func FindSubscriptions(websiteURL string) (Subscriptions, error) {
func FindSubscriptions(websiteURL, username, password string) (Subscriptions, error) {
defer timer.ExecutionTime(time.Now(), fmt.Sprintf("[FindSubscriptions] url=%s", websiteURL))
clt := client.New(websiteURL)
clt.WithCredentials(username, password)
response, err := clt.Get()
if err != nil {
if _, ok := err.(errors.LocalizedError); ok {