Improved retries
Signed-off-by: Marcus Noble <github@marcusnoble.co.uk>
This commit is contained in:
@@ -110,7 +110,7 @@ func GetLatestBooks() (map[string]*Book, error) {
|
||||
func getRating(bookID string) string {
|
||||
resp, err := c.Get(fmt.Sprintf("https://app.thestorygraph.com/books/%s/community_reviews", bookID))
|
||||
if err != nil {
|
||||
fmt.Println("Error fetching book rating:", resp.StatusCode)
|
||||
fmt.Println("Error fetching book rating:", err)
|
||||
return "0.0"
|
||||
}
|
||||
defer resp.Body.Close()
|
||||
|
||||
Reference in New Issue
Block a user