Adding hide community. Fixes #183

This commit is contained in:
Dessalines 2023-09-18 18:08:34 -04:00
parent e91444a611
commit 51b17fe7f9

View file

@ -136,6 +136,7 @@ import { VerifyEmailResponse } from "./types/VerifyEmailResponse";
import { UploadImage, UploadImageResponse, VERSION } from "./types/others";
import { BlockInstance } from "./types/BlockInstance";
import { BlockInstanceResponse } from "./types/BlockInstanceResponse";
import { HideCommunity } from "./types/HideCommunity";
enum HttpType {
Get = "GET",
@ -345,6 +346,19 @@ export class LemmyHttp {
);
}
/**
* Hide a community from public view.
*
* `HTTP.PUT /community/hide`
*/
hideCommunity(form: HideCommunity) {
return this.#wrapper<HideCommunity, CommunityResponse>(
HttpType.Put,
"/community/hide",
form,
);
}
/**
* A moderator remove for a community.
*