Make uploads only viewable to oneself (#2540)

This commit is contained in:
SleeplessOne1917 2024-06-15 01:16:17 +00:00 committed by GitHub
parent 35b3cec2d4
commit 2f91700074
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 6 additions and 2 deletions

@ -1 +1 @@
Subproject commit 866cf9f6469f99598be93dcce5e40f85d202ac22
Subproject commit c3594b4fc024c2ac6a8dab7a97fda5350a5d77e1

View file

@ -301,6 +301,10 @@ export class Profile extends Component<ProfileRouteProps, ProfileState> {
fetchUploadsToken?: symbol;
async fetchUploads(props: ProfileRouteProps) {
if (!this.amCurrentUser) {
return;
}
const token = (this.fetchUploadsToken = Symbol());
const { page } = props;
this.setState({ uploadsRes: LOADING_REQUEST });
@ -553,7 +557,7 @@ export class Profile extends Component<ProfileRouteProps, ProfileState> {
{this.getRadio(PersonDetailsView.Comments)}
{this.getRadio(PersonDetailsView.Posts)}
{this.amCurrentUser && this.getRadio(PersonDetailsView.Saved)}
{this.getRadio(PersonDetailsView.Uploads)}
{this.amCurrentUser && this.getRadio(PersonDetailsView.Uploads)}
</div>
);
}