This commit is contained in:
2025-04-07 22:23:36 +10:00
parent 3d28910178
commit fb58744928
78 changed files with 172 additions and 213 deletions

View File

@@ -26,7 +26,7 @@ func NewCompanies(request func(URL string, dataBody any) (*resty.Response, error
}
func (a *Companies) Query(query string) ([]*pb.Company, error) {
resp, err := a.request("https://api.igdb.com/v4/companies.pb", query)
resp, err := a.request(fmt.Sprintf("https://api.igdb.com/v4/%s.pb", a.endpointName), query)
if err != nil {
return nil, fmt.Errorf("failed to request: %w", err)
}