Add limited
attribute to accounts in REST API and a warning in web UI (#18344)
This commit is contained in:
parent
898fe2fa8e
commit
b4d373a3df
13 changed files with 166 additions and 59 deletions
|
@ -175,3 +175,11 @@ export const getAccountGallery = createSelector([
|
|||
|
||||
return medias;
|
||||
});
|
||||
|
||||
export const getAccountHidden = createSelector([
|
||||
(state, id) => state.getIn(['accounts', id, 'hidden']),
|
||||
(state, id) => state.getIn(['relationships', id, 'following']) || state.getIn(['relationships', id, 'requested']),
|
||||
(state, id) => id === me,
|
||||
], (hidden, followingOrRequested, isSelf) => {
|
||||
return hidden && !(isSelf || followingOrRequested);
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue