Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix duplicate activities #6627

Merged
merged 1 commit into from
Aug 14, 2024
Merged

Fix duplicate activities #6627

merged 1 commit into from
Aug 14, 2024

Conversation

lucasbordeau
Copy link
Contributor

@lucasbordeau lucasbordeau commented Aug 14, 2024

Activity creation was duplicating the new activity on already visited records of the same type.

The fix was to activate shouldMatchRootQueryFilter on createOne for activity.

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR Summary

This pull request addresses a bug causing activity duplication for previously visited records of the same type. The fix involves a small but impactful change in the useOpenCreateActivityDrawer hook.

  • Added shouldMatchRootQueryFilter: true to createOneRecord for activity targets in packages/twenty-front/src/modules/activities/hooks/useOpenCreateActivityDrawer.ts
  • This change ensures that newly created activities match the root query filter, preventing duplication
  • The fix is expected to resolve issues with redundant activities appearing for records of the same type
  • The modification is minimal but could significantly improve the user experience by eliminating duplicate entries

1 file(s) reviewed, no comment(s)
Edit PR Review Bot Settings

@charlesBochet charlesBochet merged commit c63c18a into main Aug 14, 2024
11 of 13 checks passed
@charlesBochet charlesBochet deleted the fix/activity-bug-2 branch August 14, 2024 16:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants