Fix duplicate event filtering in EventFeed

The EventFeed component was filtering events twice:
1. First in useEvents hook (backend query with event_types filter)
2. Then again in EventFeed component (client-side filter)

This caused filter issues where switching between filters would show
incorrect events (e.g., switching from SESSIONS to ALL would only show
session events).

Fixed by removing the duplicate client-side filter, as useEvents already
provides correctly filtered events from the backend.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
felix.zoesch
2025-12-15 12:10:10 +01:00
parent 8404f499f3
commit d9459b1107

View File

@@ -26,11 +26,8 @@ export const EventFeed: React.FC<EventFeedProps> = ({
}) => {
const [activeTab, setActiveTab] = useState<'feed' | 'graph'>('feed');
// Filter events by active filter
const filteredEvents = events.filter((event) => {
const allowedTypes: EventType[] = EVENT_FILTER_MAP[activeFilter];
return allowedTypes.includes(event.event_type);
});
// Events are already filtered by useEvents hook, no need to filter again
const filteredEvents = events;
// Scroll handler for infinite scroll
useEffect(() => {