github api: EnumTags

This commit is contained in:
xushiwei
2025-05-10 11:27:50 +08:00
parent 337c6cfa25
commit decb9d7f11

View File

@@ -72,11 +72,7 @@ func EnumTags(pkgPath string, page int, pager func(tags []*Tag, page, total int)
ubase := tagsURL(pkgPath) ubase := tagsURL(pkgPath)
loop: loop:
u := ubase u := ubase + "?per_page=100&page=" + strconv.Itoa(page+1)
if page > 0 {
vals := url.Values{"page": []string{strconv.Itoa(page + 1)}}
u += "?" + vals.Encode()
}
resp, err := http.Get(u) resp, err := http.Get(u)
if err != nil { if err != nil {
return return