From 3e17876ecf37f08c196a467914b91a9d346967a2 Mon Sep 17 00:00:00 2001 From: milarin Date: Fri, 3 Mar 2023 15:10:27 +0100 Subject: [PATCH] fixed Get method references --- api.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/api.go b/api.go index f4c0560..77be7cd 100644 --- a/api.go +++ b/api.go @@ -26,7 +26,7 @@ func NewApi(cookie string) *Api { } func (api *Api) GetReadingList(ctx context.Context, listIndex int) (*ReadingList, error) { - doc, err := api.getWithCookie(ctx, fmt.Sprintf("https://www.novelupdates.com/reading-list/?list=%d", listIndex)) + doc, err := api.GetWithCookie(ctx, fmt.Sprintf("https://www.novelupdates.com/reading-list/?list=%d", listIndex)) if err != nil { return nil, err } @@ -76,7 +76,7 @@ func (api *Api) GetReadingList(ctx context.Context, listIndex int) (*ReadingList } func (api *Api) GetNovelByID(novelID NovelID) (*Novel, error) { - doc, err := api.get(context.Background(), fmt.Sprintf("https://www.novelupdates.com/series/%s/", novelID)) + doc, err := api.Get(context.Background(), fmt.Sprintf("https://www.novelupdates.com/series/%s/", novelID)) if err != nil { return nil, err } @@ -134,7 +134,7 @@ func (api *Api) GetChapterEntriesByNovelID(novelID NovelID) *Cursor[NovelChapter go func() { defer close(out) - doc, err := api.get(ctx, fmt.Sprintf("https://www.novelupdates.com/series/%s/?pg=%d", novelID, 1)) + doc, err := api.Get(ctx, fmt.Sprintf("https://www.novelupdates.com/series/%s/?pg=%d", novelID, 1)) if err != nil { fmt.Fprintln(os.Stderr, err) return @@ -171,7 +171,7 @@ func (api *Api) GetChapterEntriesByNovelID(novelID NovelID) *Cursor[NovelChapter } func (api *Api) getChapterEntriesByPageIndex(ctx context.Context, novelID NovelID, pageIndex int) ([]NovelChapterEntry, error) { - doc, err := api.get(ctx, fmt.Sprintf("https://www.novelupdates.com/series/%s/?pg=%d", novelID, pageIndex)) + doc, err := api.Get(ctx, fmt.Sprintf("https://www.novelupdates.com/series/%s/?pg=%d", novelID, pageIndex)) if err != nil { return nil, err }