This commit is contained in:
Felix Ableitner 2024-11-05 10:40:07 +01:00
parent 90640a4d78
commit 491c0ad67b

View file

@ -488,26 +488,36 @@ export class LemmyHttp {
); );
} }
getCommunityPendingFollowsCount(community_id: CommunityId) { getCommunityPendingFollowsCount(
community_id: CommunityId,
options?: RequestOptions,
) {
const form: GetCommunityPendingFollowsCount = { community_id }; const form: GetCommunityPendingFollowsCount = { community_id };
return this.#wrapper< return this.#wrapper<
GetCommunityPendingFollowsCount, GetCommunityPendingFollowsCount,
GetCommunityPendingFollowsCountResponse GetCommunityPendingFollowsCountResponse
>(HttpType.Get, "/community/pending_follows/count", form); >(HttpType.Get, "/community/pending_follows/count", form, options);
} }
listCommunityPendingFollows(form: ListCommunityPendingFollows) { listCommunityPendingFollows(
form: ListCommunityPendingFollows,
options?: RequestOptions,
) {
return this.#wrapper< return this.#wrapper<
ListCommunityPendingFollows, ListCommunityPendingFollows,
ListCommunityPendingFollowsResponse ListCommunityPendingFollowsResponse
>(HttpType.Get, "/community/pending_follows/list", form); >(HttpType.Get, "/community/pending_follows/list", form, options);
} }
approveCommunityPendingFollow(form: ApproveCommunityPendingFollower) { approveCommunityPendingFollow(
form: ApproveCommunityPendingFollower,
options?: RequestOptions,
) {
return this.#wrapper<ApproveCommunityPendingFollower, SuccessResponse>( return this.#wrapper<ApproveCommunityPendingFollower, SuccessResponse>(
HttpType.Post, HttpType.Post,
"/community/pending_follows/approve", "/community/pending_follows/approve",
form, form,
options,
); );
} }