[Glitch] Add notifications for new sign-ups

Port 7b816eb5ae to glitch-soc

Signed-off-by: Claire <claire.github-309c@sitedethib.com>
This commit is contained in:
Eugen Rochko
2022-02-23 16:45:22 +01:00
committed by Claire
parent 3d25fe0426
commit f99943cd74
5 changed files with 135 additions and 2 deletions

View File

@ -57,7 +57,7 @@ defineMessages({
});
const fetchRelatedRelationships = (dispatch, notifications) => {
const accountIds = notifications.filter(item => item.type === 'follow').map(item => item.account.id);
const accountIds = notifications.filter(item => ['follow', 'follow_request', 'admin.sign_up'].indexOf(item.type) !== -1).map(item => item.account.id);
if (accountIds > 0) {
dispatch(fetchRelationships(accountIds));
@ -144,6 +144,7 @@ const excludeTypesFromFilter = filter => {
'poll',
'status',
'update',
'admin.sign_up',
]);
return allTypes.filterNot(item => item === filter).toJS();