1
0
mirror of https://github.com/mastodon/mastodon synced 2024-11-28 14:58:21 +09:00

Fix notification filter bar incorrectly filtering gaps (#14808)

This commit is contained in:
ThibG 2020-09-16 20:17:16 +02:00 committed by GitHub
parent 5d3c8baa9a
commit aab867b0e8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -32,7 +32,7 @@ const getNotifications = createSelector([
// we need to turn it off for FilterBar in order not to block ourselves from seeing a specific category // we need to turn it off for FilterBar in order not to block ourselves from seeing a specific category
return notifications.filterNot(item => item !== null && excludedTypes.includes(item.get('type'))); return notifications.filterNot(item => item !== null && excludedTypes.includes(item.get('type')));
} }
return notifications.filter(item => item !== null && allowedType === item.get('type')); return notifications.filter(item => item === null || allowedType === item.get('type'));
}); });
const mapStateToProps = state => ({ const mapStateToProps = state => ({