1
0
Fork 0
mirror of https://github.com/miniflux/v2.git synced 2025-08-01 17:38:37 +00:00

Rename internal url package to avoid overlap with net/url

This commit is contained in:
Frédéric Guillot 2023-08-13 19:09:01 -07:00
parent 9f465fd70d
commit e5d9f2f5a0
23 changed files with 74 additions and 75 deletions

View file

@ -10,7 +10,7 @@ import (
"net/http"
"time"
"miniflux.app/v2/internal/url"
"miniflux.app/v2/internal/urllib"
"miniflux.app/v2/internal/version"
)
@ -36,7 +36,7 @@ func (c *Client) AddBookmark(entryURL, entryTitle string) error {
return fmt.Errorf("shiori: unable to authenticate: %v", err)
}
apiEndpoint, err := url.JoinBaseURLAndPath(c.baseURL, "/api/bookmarks")
apiEndpoint, err := urllib.JoinBaseURLAndPath(c.baseURL, "/api/bookmarks")
if err != nil {
return fmt.Errorf("shiori: invalid API endpoint: %v", err)
}
@ -77,7 +77,7 @@ func (c *Client) AddBookmark(entryURL, entryTitle string) error {
}
func (c *Client) authenticate() (sessionID string, err error) {
apiEndpoint, err := url.JoinBaseURLAndPath(c.baseURL, "/api/login")
apiEndpoint, err := urllib.JoinBaseURLAndPath(c.baseURL, "/api/login")
if err != nil {
return "", fmt.Errorf("shiori: invalid API endpoint: %v", err)
}