diff --git a/src/platforms/modrinth/modrinth-api-client.ts b/src/platforms/modrinth/modrinth-api-client.ts index 342824d..2fb8eb2 100644 --- a/src/platforms/modrinth/modrinth-api-client.ts +++ b/src/platforms/modrinth/modrinth-api-client.ts @@ -115,18 +115,14 @@ export class ModrinthApiClient { } /** - * Fetches multiple projects by their IDs. + * Fetches multiple projects by their IDs and/or slugs. * - * @param ids - The project IDs. + * @param idsOrSlugs - The project IDs and/or slugs. * * @returns An array of projects. - * - * @remarks - * - * This method **DOES NOT** support slugs (for some reason). */ - async getProjects(ids: Iterable): Promise { - const response = await this._fetch("/projects", HttpRequest.get().with({ ids: JSON.stringify(asArray(ids)) })); + async getProjects(idsOrSlugs: Iterable): Promise { + const response = await this._fetch("/projects", HttpRequest.get().with({ ids: JSON.stringify(asArray(idsOrSlugs)) })); return (await response.json()) ?? []; }