Adding blockcommunityresponse

This commit is contained in:
Dessalines 2021-08-11 11:28:37 -04:00
parent bf194f306b
commit ba624540c9
2 changed files with 7 additions and 3 deletions

View file

@ -17,6 +17,7 @@ import {
BanFromCommunity, BanFromCommunity,
BanFromCommunityResponse, BanFromCommunityResponse,
BlockCommunity, BlockCommunity,
BlockCommunityResponse,
CommunityResponse, CommunityResponse,
CreateCommunity, CreateCommunity,
DeleteCommunity, DeleteCommunity,
@ -173,7 +174,7 @@ export class LemmyHttp {
return this.wrapper(HttpType.Post, '/community/follow', form); return this.wrapper(HttpType.Post, '/community/follow', form);
} }
async blockCommunity(form: BlockCommunity): Promise<CommunityResponse> { async blockCommunity(form: BlockCommunity): Promise<BlockCommunityResponse> {
return this.wrapper(HttpType.Post, '/community/block', form); return this.wrapper(HttpType.Post, '/community/block', form);
} }

View file

@ -1,7 +1,5 @@
import { import {
CommunityFollowerView,
CommunityModeratorView, CommunityModeratorView,
CommunityBlockView,
CommunityView, CommunityView,
PersonViewSafe, PersonViewSafe,
} from '../views'; } from '../views';
@ -117,3 +115,8 @@ export interface BlockCommunity {
block: boolean; block: boolean;
auth: string; auth: string;
} }
export interface BlockCommunityResponse {
community_view: CommunityView;
blocked: boolean;
}