Merge branch 'main' into route-data-refactor
This commit is contained in:
commit
4d716e039b
25 changed files with 194 additions and 201 deletions
|
@ -375,7 +375,6 @@ export class Community extends Component<
|
|||
community_view={res.community_view}
|
||||
moderators={res.moderators}
|
||||
admins={site_res.admins}
|
||||
online={res.online}
|
||||
enableNsfw={enableNsfw(site_res)}
|
||||
editable
|
||||
allLanguages={site_res.all_languages}
|
||||
|
@ -662,6 +661,12 @@ export class Community extends Component<
|
|||
const blockCommunityRes = await HttpService.client.blockCommunity(form);
|
||||
if (blockCommunityRes.state == "success") {
|
||||
updateCommunityBlock(blockCommunityRes.data);
|
||||
this.setState(s => {
|
||||
if (s.communityRes.state == "success") {
|
||||
s.communityRes.data.community_view.blocked =
|
||||
blockCommunityRes.data.blocked;
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue