Merge pull request #1622 from pascaldevink/fix_feedback_on_ban_and_unban

Fix feedback on banning an unbanning
This commit is contained in:
SleeplessOne1917 2023-06-26 21:10:52 +00:00 committed by GitHub
commit 961345b811
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -205,6 +205,7 @@ export class Profile extends Component<
this.handleSavePost = this.handleSavePost.bind(this); this.handleSavePost = this.handleSavePost.bind(this);
this.handlePurgePost = this.handlePurgePost.bind(this); this.handlePurgePost = this.handlePurgePost.bind(this);
this.handleFeaturePost = this.handleFeaturePost.bind(this); this.handleFeaturePost = this.handleFeaturePost.bind(this);
this.handleModBanSubmit = this.handleModBanSubmit.bind(this);
// Only fetch the data if coming from another route // Only fetch the data if coming from another route
if (FirstLoadService.isFirstLoad) { if (FirstLoadService.isFirstLoad) {
@ -987,6 +988,7 @@ export class Profile extends Component<
s.personRes.data.comments s.personRes.data.comments
.filter(c => c.creator.id == banRes.data.person_view.person.id) .filter(c => c.creator.id == banRes.data.person_view.person.id)
.forEach(c => (c.creator.banned = banRes.data.banned)); .forEach(c => (c.creator.banned = banRes.data.banned));
s.personRes.data.person_view.person.banned = banRes.data.banned;
} }
return s; return s;
}); });